Page MenuHomePhabricator

[Task] Provide RDF mapping for geoshape data type.
Closed, ResolvedPublic

Description

The RDF mapping of the geoshape datatype is not correct yet. Geoshapes are currently represented as strings in RDF, instead of the URLs of the actual shape.

In RdfBuilder::propertyIsLink(), there is a hard-coded list of data types that should be treated as URLs. geoshapes Need to be added to the list.

Conceptually, geoshapes should be handled similarly to the commonsMedia types in the RDF mapping. This means we need a GeoShapeRdfBuilder similar to CommonsMediaRdfBuilder, and RdfVocabulary::getGeoShapeURI similar to RdfVocabulary::getCommonsURI (which should probably be renamed to getMediaURI).

According to T161527: RFC: Canonical data URLs for machine readable page content, the canonical URL for pages in the Data namespace on commons should have the following form:

https://commons.wikimedia.org/data/main/Data:Xyz.map

See also the relevant design document.

Event Timeline

Restricted Application added a subscriber: Aklapper. · View Herald TranscriptMar 15 2017, 3:25 PM

@daniel can you clarify the problem with the current mapping and how it should be?

Hey I wanted to know more about the bug..

daniel renamed this task from [Task] Fix issues in geoshape datatype RDF mapping to [Task] Provide RDF mapping for geoshape data type..Mar 16 2017, 5:59 PM
daniel raised the priority of this task from Normal to High.
daniel updated the task description. (Show Details)

Bumping to high, since this blocks deployment IMHO. If we deploy without this mapping, we will end up with inconsistent data in the triple store once we fix this.

@Lydia_Pintscher i hope it's clear now.

Change 343361 had a related patch set uploaded (by Daniel Kinzler):
[mediawiki/extensions/Wikibase] Add RDF mapping for geo-shape data type [DNM]

https://gerrit.wikimedia.org/r/343361

Change 343865 had a related patch set uploaded (by Thiemo Mättig (WMDE)):
[mediawiki/extensions/Wikibase] Implement temporary null RDF mapping for GeoShapes

https://gerrit.wikimedia.org/r/343865

Change 343893 had a related patch set uploaded (by Thiemo Mättig (WMDE)):
[mediawiki/extensions/Wikibase] Add test for null implementation of GeoShape RDF mapping

https://gerrit.wikimedia.org/r/343893

daniel updated the task description. (Show Details)Mar 21 2017, 7:21 PM
daniel updated the task description. (Show Details)
daniel updated the task description. (Show Details)

Change 343865 merged by jenkins-bot:
[mediawiki/extensions/Wikibase] Implement temporary null RDF mapping for GeoShapes

https://gerrit.wikimedia.org/r/343865

Change 343893 merged by jenkins-bot:
[mediawiki/extensions/Wikibase] Add test for null implementation of GeoShape RDF mapping

https://gerrit.wikimedia.org/r/343893

Change 358911 had a related patch set uploaded (by Ladsgroup; owner: Amir Sarabadani):
[mediawiki/extensions/Wikibase@master] Make GeoShapeRdfBuilder actually work

https://gerrit.wikimedia.org/r/358911

@Smalyshev can we go ahead with this? shouldn't break anything, just add stuff for items that get edited. and we have a re-load coming up anyway, right?

In general, yes, but see my comments on the patch. PropertyRdfBuilder::propertyIsLink should be updated. If we don't have any GeoShape properties yet, it doesn't matter too much, and yes, we'll reload for T166244 as soon as we merge the patch.

Restricted Application added a project: User-Ladsgroup. · View Herald TranscriptJun 15 2017, 8:17 AM
thiemowmde closed this task as Resolved.Jun 15 2017, 10:37 AM
thiemowmde moved this task from Review to Done on the Wikidata-Former-Sprint-Board board.
thiemowmde removed a project: Patch-For-Review.

Change 358911 merged by jenkins-bot:
[mediawiki/extensions/Wikibase@master] Make GeoShapeRdfBuilder actually work

https://gerrit.wikimedia.org/r/358911

Change 343361 abandoned by Daniel Kinzler:
Add RDF mapping for geo-shape data type [DNM]

https://gerrit.wikimedia.org/r/343361