gjhiggins/rdflib — Issue #37: n3 parser doesn't error on corrupt terms
Author: gjhiggins
Created: 2011-10-19 01:01:46+00:00
State: open

Originally filed by drewpca on 2009-02-06T07:34:54

What steps will reproduce the problem?

from rdflib.Graph import Graph
from rdflib import StringInputSource
g.parse(StringInputSource(":a b c."), format='n3')
list(g.triples((None,None,None)))

->
[(rdflib.URIRef('file:///home/drewp/#a'),
rdflib.URIRef('file:///home/drewp/#b'),
rdflib.URIRef('file:///home/drewp/#c'))]

I think that should have errored because the empty prefix was not defined.
And maybe also because b and c were unknown.