Skip to content

Commit

Permalink
Obj ID typing correction
Browse files Browse the repository at this point in the history
  • Loading branch information
robamu committed May 5, 2024
1 parent 7d726c4 commit 9aec29a
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ Starting from v4.0.0, this project adheres to [Semantic Versioning](http://semve
## Changed

- Renamed `FsfwTmTcPrinter.get_validity_buffer` to `FsfwTmTcPrinter.get_validity_buffer_str`
- Renamed `ObjectId<$TY>.from_bytes` to `ObjectId<$TY>.from_bytes_typed` to avoid invalid override.

## Added

Expand Down
6 changes: 3 additions & 3 deletions tmtccmd/util/obj_id.py
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ def __repr__(self):
)

@classmethod
def from_bytes(cls, obj_id_as_bytes: bytes) -> ObjectIdU32:
def from_bytes_typed(cls, obj_id_as_bytes: bytes) -> ObjectIdU32:
obj_id = ObjectIdU32(obj_id=0)
obj_id.obj_id = obj_id_as_bytes
return obj_id
Expand All @@ -88,7 +88,7 @@ def __repr__(self):
)

@classmethod
def from_bytes(cls, obj_id_as_bytes: bytes) -> ObjectIdU16:
def from_bytes_typed(cls, obj_id_as_bytes: bytes) -> ObjectIdU16:
obj_id = ObjectIdU16(obj_id=0)
obj_id.obj_id = obj_id_as_bytes
return obj_id
Expand All @@ -108,7 +108,7 @@ def __repr__(self):
)

@classmethod
def from_bytes(cls, obj_id_as_bytes: bytes) -> ObjectIdU8:
def from_bytes_typed(cls, obj_id_as_bytes: bytes) -> ObjectIdU8:
obj_id = ObjectIdU8(obj_id=0)
obj_id.obj_id = obj_id_as_bytes
return obj_id
Expand Down

0 comments on commit 9aec29a

Please sign in to comment.