Page MenuHomePhabricator

Constraint status is still parsed with old constraint parameter parser
Closed, ResolvedPublic

Description

I’ve left this snippet of code untouched in most of the checkers where I exchanged ConstraintParameterParser for ConstraintStatementParameterParser:

if ( array_key_exists( 'constraint_status', $constraintParameters ) ) {
     $parameters['constraint_status'] = $this->constraintParameterParser->parseSingleParameter( $constraintParameters['constraint_status'], true );
 }

But $constraintParameterParser is now a ConstraintStatementParameterParser, which has no parseSingleParameter method! That’s fine in the tests and on the test systems, since we don’t have constraints with a constraint_status – but if we deploy this on Wikidata, it will blow up.

Since I don’t think T164254: Distinguish between non-mandatory and mandatory constraints will get done before the next deployment, I think the simplest (and most backportable) fix is to just remove those lines completely. They’re probably not useful for T164254 anyways – this information should be extracted in one central place, not copied into all of the checkers.

Event Timeline

Restricted Application added a subscriber: Aklapper. · View Herald TranscriptJun 22 2017, 2:06 PM

Change 360850 had a related patch set uploaded (by Lucas Werkmeister (WMDE); owner: Lucas Werkmeister (WMDE)):
[mediawiki/extensions/WikibaseQualityConstraints@master] Remove constraint_status parsing from checkers

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

I believe eab99c1ad7 is the first commit affected by this. If that commit is in a release train, I38d39a8c34 has to be included in the same train (backported if necessary).

It looks like that commit is part of 1.30.0-wmf.6. It’s unclear when this will hit Wikidata.

Change 360850 merged by jenkins-bot:
[mediawiki/extensions/WikibaseQualityConstraints@master] Remove constraint_status parsing from checkers

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

Jonas closed this task as Resolved.Jun 22 2017, 4:10 PM
Jonas moved this task from Review to Done on the Wikidata-Former-Sprint-Board board.
Lucas_Werkmeister_WMDE reopened this task as Open.Jun 22 2017, 4:14 PM

Reopening until we know that this won’t hit wikidata.org. I still don’t know what the deployment situation is there, and addshore and aude aren’t online right now.

Lucas_Werkmeister_WMDE closed this task as Resolved.Jun 23 2017, 6:18 AM

According to Katie, the next Wikidata deployment will happen next week, and will use a new branch (which should include the fix commit), so it looks like we can close this.