walidazizi / rdflib

Automatically exported from code.google.com/p/rdflib
Other
0 stars 0 forks source link

Serialisation format "rdf/xml" does not exist #185

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. Observed example on http://code.google.com/p/rdflib/wiki/FAQ which uses:

myGraph.serialize(target_rdfxml, format="rdf/xml")

2. Try running the short script below

from rdflib.graph import Graph
g = Graph()
g.parse("http://www.w3.org/2000/10/rdf-tests/rdfcore/ntriples/test.nt", 
format="nt")
print g.serialize(format="rdf/xml")

What is the expected output? What do you see instead?

Traceback (most recent call last):
  File "make_rdf.py", line 5, in <module>
    print g.serialize(format="rdf/xml")
  File "/Library/Python/2.7/site-packages/rdflib/graph.py", line 679, in serialize
    serializer = plugin.get(format, Serializer)(self)
  File "/Library/Python/2.7/site-packages/rdflib/plugin.py", line 91, in get
    raise PluginException("No plugin registered for (%s, %s)" % (name, kind))
rdflib.plugin.PluginException: No plugin registered for (rdf/xml, <class 
'rdflib.serializer.Serializer'>)

What version of the product are you using? On what operating system?

rdflib 3.1.0 (installed from source)
Max OS X 10.7 Lion
Python 2.7 (Apple provided)

Please provide any additional information below.

The alternative format of "xml" works and looking at the code it seems to give 
rdf/xml
http://code.google.com/p/rdflib/source/browse/rdflib/plugin.py

Original issue reported on code.google.com by p.j.a.c...@googlemail.com on 24 Aug 2011 at 5:55

GoogleCodeExporter commented 8 years ago
this was an error on the wikipage - I've corrected it. 

(none of the other formats are available as rdf/X either, i.e. no rdf/n3, etc.) 

Original comment by gromgull on 24 Aug 2011 at 6:49