RDFLib/rdflib — Issue #99: Move from current N3 parser to the one from CWM
Author: gjhiggins
Created: 2012-02-20 08:32:42+00:00
State: open

gromgull, 2010-01-31T15:34:30.000Z

The CWM parser is more or less defining the N3 "standard".

Sean B. Palmer has already disconnected it from CWM here:

http://inamidst.com/list/sw/trio/

I propose we take this and integrate it into rdflib. This would solve a
bunch of N3 related tickets: #4, #22, #29, #38, #84, #68 ...

The question is to do this before a 2.5 release?

Comment 2 by eik...@gmail.com
We already have a few big changes going into 2.5 and so it seems to me like it might be a good time to make this
relatively big change as well.

Comment 3 by gromgull
Committed in r1755

Comment 4 by drewpca
pyflakes has a lot of complaints about this code:

rdflib/trunk% pyflakes rdflib/syntax/parsers/notation3.py
rdflib/syntax/parsers/notation3.py:36: 'codecs' imported but unused
rdflib/syntax/parsers/notation3.py:37: 'urllib' imported but unused
rdflib/syntax/parsers/notation3.py:42: 'warn' imported but unused
rdflib/syntax/parsers/notation3.py:43: 'index' imported but unused
rdflib/syntax/parsers/notation3.py:443: redefinition of unused 'XMLNS' from line 441
rdflib/syntax/parsers/notation3.py:874: undefined name 'PARSES_TO_URI'
rdflib/syntax/parsers/notation3.py:880: undefined name 'subj'
rdflib/syntax/parsers/notation3.py:1736: undefined name 'startline'
rdflib/syntax/parsers/notation3.py:2008: undefined name 'args'
rdflib/syntax/parsers/notation3.py:2225: redefinition of function 'setDefaultNamespace' from
line 2205
rdflib/syntax/parsers/notation3.py:2734: undefined name 'FRESH'
rdflib/syntax/parsers/notation3.py:2784: undefined name 'bNodes'
rdflib/syntax/parsers/notation3.py:2786: undefined name 'bNodes'
rdflib/syntax/parsers/notation3.py:2788: undefined name 'bNodes'

Comment 5 by gromgull
Fixed in r1764

I removed the N3 serialising code from notoation3.py, if we see the need to change to
this one later then we can re-copy it from the trio repository.