Page MenuHomePhabricator

Math PHPUnit fail due to WikibaseQuality SpecialConstraintReportTest: <span class="wbqc-status wbqc-status-warning"/> not found
Closed, ResolvedPublic

Description

On a dummy change made to the Math extension (436237), a PHPUnit test is failling: Test report.

Seems the hamcrest test is looking for <span class="wbqc-status wbqc-status-warning"/> but the HTML item has a wbqc-status-todo class.

Note that in CI Math depends on Wikibase and thus there is a lot of dependencies:

mediawiki/extensions/Math 
mediawiki/extensions/BetaFeatures
mediawiki/extensions/Capiunto
mediawiki/extensions/CentralAuth
mediawiki/extensions/CirrusSearch
mediawiki/extensions/Cite
mediawiki/extensions/Echo
mediawiki/extensions/EducationProgram
mediawiki/extensions/Elastica
mediawiki/extensions/EventLogging
mediawiki/extensions/GeoData
mediawiki/extensions/MwEmbedSupport
mediawiki/extensions/PdfHandler
mediawiki/extensions/PropertySuggester
mediawiki/extensions/Scribunto
mediawiki/extensions/SiteMatrix
mediawiki/extensions/SyntaxHighlight_GeSHi
mediawiki/extensions/TimedMediaHandler
mediawiki/extensions/VisualEditor
mediawiki/extensions/WikiEditor
mediawiki/extensions/Wikibase
mediawiki/extensions/WikibaseQuality
mediawiki/extensions/WikibaseQualityConstraints
mediawiki/extensions/WikimediaBadges
mediawiki/extensions/cldr

Event Timeline

hashar created this task.Jun 12 2018, 4:50 PM
Restricted Application added a project: Wikidata. · View Herald TranscriptJun 12 2018, 4:50 PM
Restricted Application added a subscriber: Aklapper. · View Herald Transcript

Change 439977 had a related patch set uploaded (by Lucas Werkmeister (WMDE); owner: Lucas Werkmeister (WMDE)):
[mediawiki/extensions/WikibaseQualityConstraints@master] Don’t cache constraints when running unit tests

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

I haven’t been able to reproduce this locally yet, but I have a hunch – see the above change. (Is the CI failure reliable or flaky?)

hashar removed a project: Math.Jun 12 2018, 5:08 PM

In CI, WikibaseQuality does not depend on Math:

$ colordiff -u Math WikibaseQuality 
--- Math	2018-06-12 18:54:57.569521197 +0200
+++ WikibaseQuality	2018-06-12 18:55:13.609284832 +0200
@@ -1,4 +1,3 @@
-mediawiki/extensions/Math 
 mediawiki/extensions/BetaFeatures
 mediawiki/extensions/Capiunto
 mediawiki/extensions/CentralAuth

Trying a recheck on a dummy change of WikibaseQuality ( https://gerrit.wikimedia.org/r/c/mediawiki/extensions/WikibaseQuality/+/436232 ).

And it fails (without Math): https://integration.wikimedia.org/ci/job/mwext-testextension-hhvm-composer-jessie/14463/console

@Lucas_Werkmeister_WMDE dont worry that can wait tomorrow :-] Feel free to poke me on IRC tomorrow morning.

Change 439981 had a related patch set uploaded (by Lucas Werkmeister (WMDE); owner: Lucas Werkmeister (WMDE)):
[mediawiki/extensions/WikibaseQualityConstraints@master] Reset ConstraintLookup service around some tests

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

Change 439982 had a related patch set uploaded (by Lucas Werkmeister (WMDE); owner: Lucas Werkmeister (WMDE)):
[mediawiki/extensions/WikibaseQualityConstraints@master] DNM: dummy change

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

I also created a dummy change (here), and it looks like CI is failing on other extensions, but not on WikibaseQualityConstraints itself… damn.

(WikibaseQuality is an almost empty extension, by the way, which we should probably get rid of at some point. Everything important is in WikibaseQualityConstraints.)

Change 439981 merged by jenkins-bot:
[mediawiki/extensions/WikibaseQualityConstraints@master] Reset ConstraintLookup service around some tests

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

Change 439977 abandoned by Hashar:
Don’t cache constraints when running unit tests

Reason:
That was a nice quick hack to confirm. The alternative I8cdebc0eef is a bit more complicated but semantically better (it has the test suite to reset the service and cache).

Danke!

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

hashar closed this task as Resolved.Jun 13 2018, 7:53 AM
hashar assigned this task to Lucas_Werkmeister_WMDE.

I triggered builds of the Math change https://gerrit.wikimedia.org/r/c/mediawiki/extensions/Math/+/436237 and it passed all CI jobs. So I am assuming it is definitely fixed.

Danke schön!

Change 439982 abandoned by Lucas Werkmeister (WMDE):
DNM: dummy change

Reason:
No longer needed, upstream task is resolved 🎉

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

Vvjjkkii renamed this task from Math PHPUnit fail due to WikibaseQuality SpecialConstraintReportTest: <span class="wbqc-status wbqc-status-warning"/> not found to m6aaaaaaaa.Jul 1 2018, 1:04 AM
Vvjjkkii reopened this task as Open.
Vvjjkkii triaged this task as High priority.
Vvjjkkii removed Lucas_Werkmeister_WMDE as the assignee of this task.
Vvjjkkii updated the task description. (Show Details)
Vvjjkkii removed subscribers: gerritbot, Aklapper.
CommunityTechBot raised the priority of this task from High to Needs Triage.
CommunityTechBot closed this task as Resolved.
CommunityTechBot renamed this task from m6aaaaaaaa to Math PHPUnit fail due to WikibaseQuality SpecialConstraintReportTest: <span class="wbqc-status wbqc-status-warning"/> not found.
CommunityTechBot added subscribers: gerritbot, Aklapper.