Skip to content

Commit

Permalink
Merge pull request #18 from steven-murray:ignore-type
Browse files Browse the repository at this point in the history
fix: don't use the automatic 'type' param from attrs
  • Loading branch information
steven-murray committed Aug 7, 2023
2 parents 9881208 + b3b64d2 commit 766c4a6
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/hickleable/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,9 @@ def __init__(self, h5_attrs: dict, base_type: str, object_type: Any):
# __init__ method can be used to change the data structure used to
# store the subitems passed to the append method of the PyContainer
# class per default it is set to []
super().__init__(h5_attrs, base_type, object_type, _content=dict(h5_attrs))
_content = {k: v for k, v in h5_attrs.items() if k != "type"}

super().__init__(h5_attrs, base_type, object_type, _content=_content)

def append(self, name: str, item: Any, h5_attrs: AttributeManager):
"""Add a particular item to the content defining the object.
Expand Down

0 comments on commit 766c4a6

Please sign in to comment.