diff --git a/src/curies/api.py b/src/curies/api.py index 2c0986a..33d07be 100644 --- a/src/curies/api.py +++ b/src/curies/api.py @@ -630,8 +630,6 @@ def from_jsonld(cls, data: LocationOr[Dict[str, Any]]) -> "Converter": prefix_map[key] = value elif isinstance(value, dict) and value.get("@prefix") == True: prefix_map[key] = value["@id"] - else: - raise TypeError return cls.from_prefix_map(prefix_map) @classmethod diff --git a/tests/test_api.py b/tests/test_api.py index 7a8c316..ee80bda 100644 --- a/tests/test_api.py +++ b/tests/test_api.py @@ -154,7 +154,10 @@ def test_jsonld(self): "@prefix": True, "@id": "http://purl.obolibrary.org/CHEBI_", }, - } + "nope": { + "nope": "nope", + }, + }, } converter = Converter.from_jsonld(context) self.assertIn("hello", converter.prefix_map)