Closed fbelleau closed 3 months ago
First observation: Your file is not a valid N-Triples file, because the first line contains a literal number which is not in quotes.
Second observation: I tried to validate the file as a Turtle file using Serdi, and after running for some 5 minutes, got this error:
$ zcat "flymine-object.nt.gz?download=true" | serdi -i Turtle - >/dev/null
error: (stdin):122031261:1113: invalid escape `\.'
And the syntax error is obvious when looking at the end of the offending line (122031261):
<http://bio2rdf.org/flymine:Comment:17676592> <http://bio2rdf.org/flymine_voc:description> 'Calcium/calmodulin-dependent protei
n kinase that operates in the calcium-triggered CaMKK-CaMK1 signaling cascade and, upon calcium influx, regulates transcription
activators activity, cell cycle, hormone production, cell differentiation, actin filament organization and neurite outgrowth.
Recognizes the substrate consensus sequence [MVLIF]-x-R-x(2)-[ST]-x(3)-[MVLIF]. Regulates axonal extension and growth cone moti
lity in hippocampal and cerebellar nerve cells. Upon NMDA receptor-mediated Ca(2+) elevation, promotes dendritic growth in hipp
ocampal neurons and is essential in synapses for full long-term potentiation (LTP) and ERK2-dependent translational activation.
Downstream of NMDA receptors, promotes the formation of spines and synapses in hippocampal neurons by phosphorylating ARHGEF7/
BETAPIX on \'Ser-516\', which results in the enhancement of ARHGEF7 activity and activation of RAC1. Promotes neuronal differen
tiation and neurite outgrowth by activation and phosphorylation of MARK2 on \'Ser-91\', \'Ser-92\...' .
Does this help you forward, or would you need help in fixing the file?
@tuukka Thank you for helping with the analysis of the file
@fbelleau You are right to expect a better error message here. There are two errors in place here, the first being that this shouldn't read as an internal assertion, and the second one is that it should backpropagate to the parser which should give you a little more context around the offending line. I hope I'll be able to fix this some time in the future.
In general:
QLever's parser treats NTriples files as Turtle files (we have no distinct NTriples parser, but Ntriples is a subset of Turtle, that is why triples like <a> <b> 24 .
work as expected although they are technically not NTriples files.
We recommend to validate your Turtle/Ntriples files using a dedicated tool vor validation of RDF, like the validators from Apache Jena (or probably the tool that @tuukka used) if you run into problems with our parser to find out, whether the problem is in the dataset or in QLever.
Thank you for your help. I have fixed the escape problem. serdi is very useful.
I have a parsing error in my ntriple input file of more than 200 millions triples.
Here is the message:
Is there a way to know which line is in problem with a log option? Those input format errors are hard to diagnosed without proper message to identify the line involved.
The N-Triples file is available here for you to test:
https://huggingface.co/datasets/bio2rdf/flymine_nt/blob/main/flymine-object.nt.gz