Re: Testing Google's Rich Snippets RDFa support

On Tue, 2009-09-15 at 17:09 +0100, Philip Taylor wrote:
> Othar wrote:
>
> > We surely have errors in our parsing (thanks for finding several:
> > we'll look into these on Monday).  But we will also deviate from the
> > standard in some cases to be forgiving of webmaster errors.  For
> > example, we expect that some webmasters will forget the xmlns
> > attribute entirely.
> 
> "we will [...] deviate from the standard" makes me believe that the 
> above problems are an unavoidable consequence of Google's intentions, 
> rather than just unintentional transient fixable bugs, and therefore are 
> a serious concern (which is why I'm writing about it like this rather 
> than just listing bugs).

I think it's reasonable to build in a degree of laxity into an RDFa
parser. Postel's Law applies. But Google's current parsing algorithm
doesn't just forgive webmasters who make mistakes, but has the
presumably unintended consequence of punishing webmasters who publish
conforming but unexpected-by-Google RDFa.

The best way to forgive webmasters who forget to declare the 'v' CURIE
prefix would be to pre-populate the "list of URI mappings" which is
described as initially empty in
<http://www.w3.org/TR/rdfa-syntax/#sec_5.5.>. Instead, Google appears to
ignore CURIE prefix mappings altogether.

I'd previously sent to Kavi Goel at Google a few test cases which
*ought* to be to *exactly* identical results by an RDFa processor, but
Google currently seems to handle differently to each other. I'll put
them on public record now:

        <div xmlns:v="http://rdf.data-vocabulary.org/"
          about="#joe" typeof="v:Person">
                <span property="v:name">Joe Bloggs</span>
                <span property="v:nickname">Joey</span>
        </div>

        <div xmlns:v="http://rdf.data-vocabulary.org/">
                <span about="#joe"
                  typeof="v:Person"
                  property="v:name">Joe Bloggs</span>
                <span about="#joe" property="v:nickname">Joey</span>
        </div>

        <div xmlns:v="http://rdf.data-vocabulary.org/">
                <span about="#joe"
                  property="v:name">Joe Bloggs</span>
                <span about="#joe" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
                  rel="rdf:type" resource="[v:Person]"
                  property="v:nickname">Joey</span>
        </div>

        <div xmlns:v="http://rdf.data-vocabulary.org/"
          about="#joe" typeof="v:Person">
                <span xmlns:v="http://rdf.data-vocabulary.org/n"
                  property="v:ame">Joe Bloggs</span>
                <span xmlns:v="http://rdf.data-vocabulary.org/n"
                  property="v:ickname">Joey</span>
        </div>

        <div xmlns:v="http://rdf.data-vocabulary.org/"
          about="#joe" typeof="v:Person"
          property="v:nickname" content="Joey">
                <span property="v:name">Joe Bloggs</span>
                <span>Joey</span>
        </div>

-- 
Toby A Inkster
<mailto:mail@tobyinkster.co.uk>
<http://tobyinkster.co.uk>

Received on Wednesday, 16 September 2009 08:38:51 UTC