Page MenuHomePhabricator

Write a maintenance script to create entities needed for WikibaseQualityConstraints configuration
Closed, ResolvedPublic

Description

This script should:

  • Create all entities needed by WikibaseQualityConstraints for operation.
  • Output the configuration that should then be used by WikibaseQualityConstraints

Patch-For-Review:

Event Timeline

Addshore triaged this task as Medium priority.Nov 20 2018, 2:56 PM
Addshore created this task.

Isn’t this basically the “data import” section of the README? Or is this a task for rewriting that thing as a maintenance script?

One thing that was suggested was to actually make new Items and Properties for those constraints.

Well, the “data import” part does that as well :) but it uses the WikibaseImport extension, which we can’t use in production. So to answer my question, yes, we basically want to rewrite that as a maintenance script without external dependencies.

(Note that we don’t need to import statements of referenced entities, which means our “wikibase import” functionality should be a lot simpler than WikibaseImport.)

Change 476078 had a related patch set uploaded (by Lucas Werkmeister (WMDE); owner: Lucas Werkmeister (WMDE)):
[mediawiki/extensions/WikibaseQualityConstraints@master] Add maintenance script to import constraint entities

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

Change 476248 had a related patch set uploaded (by Lucas Werkmeister (WMDE); owner: Lucas Werkmeister (WMDE)):
[mediawiki/extensions/WikibaseQualityConstraints@master] Use maintenance script in README.md data import section

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

Change 476249 had a related patch set uploaded (by Lucas Werkmeister (WMDE); owner: Lucas Werkmeister (WMDE)):
[mediawiki/extensions/WikibaseQualityConstraints@master] Remove exportEntityMapping maintenance script

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

Change 476078 merged by jenkins-bot:
[mediawiki/extensions/WikibaseQualityConstraints@master] Add maintenance script to import constraint entities

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

Change 476248 merged by jenkins-bot:
[mediawiki/extensions/WikibaseQualityConstraints@master] Use maintenance script in README.md data import section

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

Change 476249 merged by jenkins-bot:
[mediawiki/extensions/WikibaseQualityConstraints@master] Remove exportEntityMapping maintenance script

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

Change 479254 had a related patch set uploaded (by Lucas Werkmeister (WMDE); owner: Lucas Werkmeister (WMDE)):
[mediawiki/extensions/WikibaseQualityConstraints@master] Don’t create the import user in dry-run mode

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

Change 479255 had a related patch set uploaded (by Lucas Werkmeister (WMDE); owner: Lucas Werkmeister (WMDE)):
[mediawiki/extensions/WikibaseQualityConstraints@master] Fix extraction of entity IDs from StorageExceptions

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

Change 479254 merged by jenkins-bot:
[mediawiki/extensions/WikibaseQualityConstraints@master] Don’t create the import user in dry-run mode

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

Change 479255 merged by jenkins-bot:
[mediawiki/extensions/WikibaseQualityConstraints@master] Fix extraction of entity IDs from StorageExceptions

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

Seems to be working (tested on Beta, successfully this time).