You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Every time the linter runs into markup containing statements about a schema.org/Person's homeLocation or workLocation it generates an error message:
property schema:location: Subject <http://example.org/#WileECoyote> not compatible with domainIncludes (schema:Action,schema:Event,schema:InteractionCounter,schema:Organization)
Somehow the location property (parent property of the others) gets shown in the output, which rightfully triggers the error message, though I am clueless as to why this property gets added. Is this a bug in the schema.org vocabulary or in the Linter?
What's extra confusing is that I only have seen it happen in regards to Person statements.
Thanks for bringing up the issue. I think it is, indeed, a bug in the linter, but a challenging one to fix. Person is a valid range of workLocation, even though it is not of location. But, because of that way that subPropertyOf works, :a :workLocation :b. implies :a :location :b..
The definition of workLocation is:
:workLocation a rdf:Property ;
rdfs:label "workLocation" ;
:domainIncludes :Person ;
:rangeIncludes :ContactPoint,
:Place ;
rdfs:comment "A contact location for a person's place of work." ;
rdfs:subPropertyOf :location .
The fact that _location` does not have Person in its range is not an error, as RDFS doesn't have error conditions. The linter is inferring a problem given the inferred triples.
The fix is probably to filter out errors of this kind, but that's going to be hard to do.
Activity
gkellogg commentedon Aug 22, 2023
Thanks for bringing up the issue. I think it is, indeed, a bug in the linter, but a challenging one to fix. Person is a valid range of workLocation, even though it is not of location. But, because of that way that subPropertyOf works,
:a :workLocation :b.implies:a :location :b..The definition of
workLocationis:From RDFS, we can see via rdfs5:
```xxx rdfs:subPropertyOf yyy . yyy rdfs:subPropertyOf zzz . => xxx rdfs:subPropertyOf zzz .`
The fact that _location` does not have Person in its range is not an error, as RDFS doesn't have error conditions. The linter is inferring a problem given the inferred triples.
The fix is probably to filter out errors of this kind, but that's going to be hard to do.
gkellogg commentedon Aug 22, 2023
Actually, the way to address it is probably to add a rule such as the following:
Same thing for schema:rangeIncludes.
jvandriel commentedon Aug 22, 2023
Thanks for the reaction @gkellogg.
I can imagine you have a ton of other things to do before tackling this. I'm already happy to know I wasn't seeing ghosts for once.
If you'll ever get around to fixing it it'd be great, if not, at least it's documented in this issue.
jvandriel commentedon Sep 28, 2023
Just for the sakes of documenting the issue in case people are searching for it, here's another example of the same issue: