SynBioDex / pySBOL3

Native python implementation of SBOL 3.0 specification
MIT License
37 stars 16 forks source link

JSONLD serialization includes bogus context #349

Closed jakebeal closed 3 years ago

jakebeal commented 3 years ago

The JSONLD serialization of SBOL documents includes a bogus context entry that points to a broken link: "@vocab": "https://sbolstandard.org/examples/"

Minimal reproduction:

doc2 = sbol3.Document()
print(doc2.write_string(sbol3.JSONLD))
{
  "@context": {
    "@om": "http://www.ontology-of-units-of-measure.org/resource/om-2/",
    "@prov": "http://www.w3.org/ns/prov#",
    "@sbol": "http://sbols.org/v3#",
    "@vocab": "https://sbolstandard.org/examples/"
  },
  "@graph": []
}
tcmitchell commented 3 years ago

You're right. This is a holdover from the original JSONLD files in SBOLTestSuite. The @vocab was removed in SBOLTestSuite in SynBioDex/SBOLTestSuite@1b7e34ea9fb196eefc7c2ac391c5c304f15f9819. This can be removed from pySBOL3. It appears in sbol3/document.py.