Skip to content

Commit

Permalink
Annotate sdo.SdoBase.network and avoid None dummy value.
Browse files Browse the repository at this point in the history
Use a _DummyNetwork object instead.
  • Loading branch information
acolomb committed Aug 11, 2024
1 parent 1c56ec1 commit d6c7ee0
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion canopen/sdo/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
from typing import Iterator, Optional, Union
from collections.abc import Mapping

import canopen.network
from canopen import objectdictionary
from canopen import variable
from canopen.utils import pretty_index
Expand Down Expand Up @@ -43,7 +44,7 @@ def __init__(
"""
self.rx_cobid = rx_cobid
self.tx_cobid = tx_cobid
self.network = None
self.network: canopen.network.Network = canopen.network._DummyNetwork()
self.od = od

def __getitem__(
Expand Down

0 comments on commit d6c7ee0

Please sign in to comment.