neo4j-labs / neosemantics

Graph+Semantics: Import/Export RDF from Neo4j. SHACL Validation, Model mapping and more.... If you like it, please ★ ⇧
https://neo4j.com/labs/neosemantics/
Apache License 2.0
826 stars 143 forks source link

Neo4j 4.0.1 fails to import ontologies #151

Open StrangeTcy opened 4 years ago

StrangeTcy commented 4 years ago

On Ubuntu 18.04 with neo4j 4.0.1 and neosemantics 3.5.0.4 (latest release at the time of this writing) I try to reproduce the results from quickgraph #9, but running the

CALL semantics.importOntology( "http://www.nsmntx.org/2019/10/clothingMaterials", "Turtle", { keepLangTag: true, handleMultival: 'ARRAY'})

query results in an error:

Failed to invoke procedure semantics.importOntology: Caused by: java.lang.NoSuchMethodError: 'org.neo4j.graphdb.schema.Schema org.neo4j.graphdb.GraphDatabaseService.schema()'

At the same time, a simple call semantics.importOntology() gets an expected error about no arguments being provided. ETA: it's the same for semantics.importRDF() and, so, quickgraph #10

My guess is that neosemantics 3.5 can't find some method in neo4j 4.0 due to some renaming, but probably that's not the cause of this.

jbarrasa commented 4 years ago

Yes, the 3.5.x releases of neosemantics were not compatible with Neo4j 4.0. Hopefully you'll be able to make it work with the 4.0.x release. The syntax will change a bit, as described in the migration guide, but it should be pretty straightforward: CALL n10s.graphconfig.init({ keepLangTag: true, handleMultival: 'ARRAY'}); CALL n10s.onto.import.fetch("http://www.nsmntx.org/2019/10/clothingMaterials", "Turtle");

Please comment if you find any issue.

Cheers,

JB.