[redland-dev] guid Parse Error with RSS
Dave Beckett
dave.beckett at bristol.ac.uk
Sat Feb 28 17:23:22 GMT 2004
On Sat, 28 Feb 2004, Simon Cox wrote:
> I'm trying to parse the attached file with rapper and I get the
> following errors:
You didn't attach the file to this re-send, but I did receive it
personally.
>
> $ rapper audioscrobbler-history.rdf
> rapper: Parsing file audioscrobbler-history.rdf
> [--snip--]
> rapper: Statement: [http://mm.musicbrainz.org/track/MBIDHERE,
> http://purl.org/rss/1.0/description, "FC Kahuna - Hayling"]
> rapper: Error - URI file:///home/simonc/irp/audioscrobbler-history.rdf:0
> column 0 - Using an element 'guid' without a namespace is forbidden.
> rapper: Failed to parse file audioscrobbler-history.rdf rdfxml content
> rapper: Parsing returned 24 statements
I'm not sure what version of things you are using, but with
raptor 1.2.0 here built with libxml it says the errors is on line 39:
<guid isPermaLink="false">684 at http://www.audioscrobbler.com/user/simoncox/</guid>
which is some kind of RSS XML, not standard RDF/XML.
I know the error message is unhelpful, in that the error is that the
isPermaLink isn't allowed (also not allowed since it has no namespace).
Delete it and it should be OK.
> The RSS ontology is defined as the default namespace.
>
> Also, it won't load the RSS tag soup parser:
>
> $ rapper -i rss-tag-soup audioscrobbler-history.rdf
> rapper: Failed to create raptor parser type rss-tag-soup
>
> Am I doing something stupid?
I suspect you have built raptor without rss-tag-soup, either
by using expat or using a version of libxml that is too old.
When you ./configure raptor, the summary tells you what it did
and there is a check for the rss-tag-soup requirements.
Of course it works OK for me:
$ rapper -i rss-tag-soup -c audioscrobbler-history.rdf
rapper: Parsing file audioscrobbler-history.rdf
rapper: Parsing returned 46 statements
(-c is just to count triples, not emit them)
The RSS tag soup's an experiment and I know it's not complete.
Last time I checked, I think it mostly did atom too, but atom
has changed many times since then. I'll likely make it do that, of
course patches are welcome.
If you've got raptor 1.2.0, you can see the built in parsers from
the help message: rapper -h
-i, --input FORMAT Set input format to one of:
'rdfxml' RDF/XML (default)
'ntriples' N-Triples
'turtle' Turtle
'rss-tag-soup' RSS tag soup
Cheers
Dave
More information about the redland-dev
mailing list