W3C home > Mailing lists > Public > public-rdfa-wg@w3.org > March 2012

Error in test or error in spec?

From: Ivan Herman <ivan@w3.org>
Date: Wed, 7 Mar 2012 11:11:13 +0100
Cc: W3C RDFWA WG <public-rdfa-wg@w3.org>
To: Gregg Kellogg <gregg@kellogg-assoc.com>
Message-Id: <BCD357D5-24E5-4E99-BF96-5A0F955BF13C@w3.org>
This is what the CR phase is good for: reveal corner cases!

A simplified version of test #58 looks as follow (simplified, because in the original tests there were two, structurally identical foaf:Person statements, but it is unnecessary here):

    <div about="http://www.example.org/#ben" rel="foaf:knows">
      <p typeof="foaf:Person" property="foaf:name">Mark Birbeck</p>
      <p typeof="foaf:Person" property="foaf:name">Ivan Herman</p>

The SPAQL test requires, essentially (I rewrote it in a somewhat more readable Turtle):

<http://www.example.org/#ben> <http://xmlns.com/foaf/0.1/knows> 
	a <http://xmlns.com/foaf/0.1/Person> ;
	?a <http://xmlns.com/foaf/0.1/name> "Mark Birbeck" 
	a <http://xmlns.com/foaf/0.1/Person> ;
	?a <http://xmlns.com/foaf/0.1/name> "Ivan Herman" 
      ] .

And I agree that this is what one would expect. (And that was also the case for RDFa 1.0.) However, this is not what the spec says:-( The relevant processing step is 5.1. New subject is set to @about or to the parent object; the presence of @typeof does _not_ change that; @typeof will create a new BNode that will be the object of the triples. The somewhat surprising outcome of the test will be, according to the spec:

<http://www.example.org/#ben> foaf:knows 
               [ foaf:name [ a foaf:Person ],
                           [ a foaf:Person ] ] .

This is, however, the outcome of the 'pattern' that we now have:

<div property="foaf:knows" typeof="foaf:Person">bla bla</div>

Ie, we have a backward incompatibility 'feature' but I think the spec is fine.

My conclusion for now: the test is wrong. We should redo altogether because, of course, with those values it looks weird and, I guess, the goal was to use it as a test for hanging rels:

   <div about="http://www.example.org/#ben" rel="foaf:knows">
      <p typeof="foaf:Person"><span property="foaf:name">Mark Birbeck</span></p>
      <p typeof="foaf:Person"><span property="foaf:name">Ivan Herman</span></p>

which indeed results in 

@prefix foaf: <http://xmlns.com/foaf/0.1/> .

<http://www.example.org/#ben> foaf:knows [ a foaf:Person;
            foaf:name "Mark Birbeck" ],
        [ a foaf:Person;
            foaf:name "Ivan Herman" ] .




Ivan Herman, W3C Semantic Web Activity Lead
Home: http://www.w3.org/People/Ivan/
mobile: +31-641044153
FOAF: http://www.ivan-herman.net/foaf.rdf

Received on Wednesday, 7 March 2012 10:11:07 UTC

This archive was generated by hypermail 2.4.0 : Friday, 17 January 2020 17:05:30 UTC