Lucas_Werkmeister_WMDE created this task.
Lucas_Werkmeister_WMDE added projects: Wikidata, Wikidata-Campsite, 
Wikibase-Quality-Constraints.
Restricted Application added a subscriber: Aklapper.

TASK DESCRIPTION
  As an editor, I only want to see constraint violations if a statement is 
actually incorrect.
  
  **Problem:**
   Currently, any property of type tabular data or geographic shape with a 
“commons link” constraint will result in a constraint violation, since 
`CommonsLinkChecker` does not handle the `Data:` namespace correctly. In 
T214856 <https://phabricator.wikimedia.org/T214856>, we taught it about the 
`Data:` namespace, but it looks like it’s still trying to parse titles in this 
namespace using a `TitleParser` for Wikidata, which doesn’t work (there’s no 
such namespace there); consequently, it then searches the database for a page 
with `page_title = Data:Highland.map` (and `page_namespace = 486`) instead of 
`page_title = Highland.map`, and reports an error when the page isn’t found. 
(Also, the `valueIncludesNamespace()` condition in `checkConstraint()` looks 
suspicious to me as well. For tabular data and geographic shapes, the namespace 
is required, as far as I can tell.)
  
  **Example:**
  https://www.wikidata.org/wiki/Q208279#P3896
  
  **Screenshots/mockups:**
  F28508259: Screenshot_2019-03-29 Highland.png 
<https://phabricator.wikimedia.org/F28508259>
  
  **BDD**
  GIVEN I am logged in
  WHEN I look at a statement of type “geographic shape” or “tabular data”
  AND the statement’s property has a “commons link” constraint (query of such 
properties 
<https://query.wikidata.org/#SELECT%20%3Fproperty%20%3FpropertyLabel%20WHERE%20%7B%0A%20%20VALUES%20%3FpropertyType%20%7B%20wikibase%3AGeoShape%20wikibase%3ATabularData%20%7D%0A%20%20%3Fproperty%20a%20wikibase%3AProperty%3B%0A%20%20%20%20%20%20%20%20%20%20%20%20wikibase%3ApropertyType%20%3FpropertyType%3B%0A%20%20%20%20%20%20%20%20%20%20%20%20wdt%3AP2302%20wd%3AQ21510852.%0A%20%20SERVICE%20wikibase%3Alabel%20%7B%20bd%3AserviceParam%20wikibase%3Alanguage%20%22%5BAUTO_LANGUAGE%5D%2Cen%22.%20%7D%0A%7D>)
  THEN I do //not// see a constraint violation (unless the value is actually 
not well-formed, e. g. uses `_` instead of ` `)
  
  **Acceptance criteria:**
  
  - `CommonsLinkChecker` recognizes the  `Data:` namespace
  
  **Open questions:**
  
  - `CommonsLinkChecker` is annoyingly difficult to test locally (the 
`commonswiki` database name is hardcoded), do we want to improve that as part 
of working on this task? (T169538 <https://phabricator.wikimedia.org/T169538>)

TASK DETAIL
  https://phabricator.wikimedia.org/T219619

EMAIL PREFERENCES
  https://phabricator.wikimedia.org/settings/panel/emailpreferences/

To: Lucas_Werkmeister_WMDE
Cc: Lucas_Werkmeister_WMDE, Aklapper, alaa_wmde, Nandana, Lahi, Gq86, 
GoranSMilovanovic, QZanden, LawExplorer, _jensen, rosalieper, Agabi10, Jonas, 
Wikidata-bugs, aude, Lydia_Pintscher, Mbch331
_______________________________________________
Wikidata-bugs mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/wikidata-bugs

Reply via email to