Skip to content

Commit

Permalink
docs
Browse files Browse the repository at this point in the history
Signed-off-by: Jan Kowalleck <jan.kowalleck@gmail.com>
  • Loading branch information
jkowalleck committed Feb 11, 2024
1 parent 508804d commit cec0bb8
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions examples/complex_deserialize.py
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,8 @@
print('JSON valid')
except MissingOptionalDependencyException as error:
print('JSON-validation was skipped due to', error)
bom_from_json = Bom.from_json(json_loads(json_data))
bom_from_json = Bom.from_json( # type: ignore[attr-defined]
json_loads(json_data))
print('bom_from_json', repr(bom_from_json))

# endregion JSON
Expand Down Expand Up @@ -254,7 +255,8 @@
print('XML valid')
except MissingOptionalDependencyException as error:
print('XML-validation was skipped due to', error)
bom_from_xml = Bom.from_xml(SafeElementTree.fromstring(xml_data))
bom_from_xml = Bom.from_xml( # type: ignore[attr-defined]
SafeElementTree.fromstring(xml_data))
print('bom_from_xml', repr(bom_from_xml))

# endregion XML
Expand Down

0 comments on commit cec0bb8

Please sign in to comment.