owlcs / owlapi

OWL API main repository
822 stars 315 forks source link

Enable download from obo URLs #1010

Open matentzn opened 3 years ago

matentzn commented 3 years ago

Right now, providing an OBO URL as an input to OWLOntologyManager::loadOntology(IRI ontologyIRI) results in an obscure error:

Parser: org.semanticweb.owlapi.oboformat.OBOFormatOWLAPIParser@7df60067
    Stack trace:
LINENO: 1 - Could not find tag separator ':' in line.
LINE: <!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">        org.semanticweb.owlapi.oboformat.OBOFormatOWLAPIParser.parse(OBOFormatOWLAPIParser.java:60)
        uk.ac.manchester.cs.owl.owlapi.OWLOntologyFactoryImpl.loadOWLOntology(OWLOntologyFactoryImpl.java:220)
        uk.ac.manchester.cs.owl.owlapi.OWLOntologyManagerImpl.actualParse(OWLOntologyManagerImpl.java:1254)
        uk.ac.manchester.cs.owl.owlapi.OWLOntologyManagerImpl.loadOntology(OWLOntologyManagerImpl.java:1208)

Try, for example:

http://purl.obolibrary.org/obo/ncbitaxon/subsets/taxslim.obo
http://purl.obolibrary.org/obo/cl.obo
http://purl.obolibrary.org/obo/ro.obo

More background: https://github.com/ontodev/robot/issues/895

I feel like this has been solved but I cannot find a corresponding ticket..