Page MenuHomePhabricator

WikidataPageBanner CI broken: url.indexOf is not a function
Closed, ResolvedPublic5 Estimated Story Points

Description

CI for mediawiki/extensions/WikidataPageBanner.git is broken, specifically the noselenium job; example console output (kept-forever version) from empty change:

11:59:59 14 08 2021 09:59:59.654:DEBUG [middleware:source-files]: Requesting /load.php?modules=ext.echo.api%2Cdm%2Cinit&version=1lc63
11:59:59 14 08 2021 09:59:59.655:DEBUG [middleware:source-files]: Fetching /load.php
11:59:59 14 08 2021 09:59:59.656:DEBUG [proxy]: proxying request - /load.php?modules=ext.echo.api%2Cdm%2Cinit&version=1lc63 to 127.0.0.1:9412
11:59:59 INFO:backend.PhpWebserver:[Sat Aug 14 09:59:59 2021] 127.0.0.1:42912 [200]: /load.php?modules=ext.echo.api%2Cdm%2Cinit&version=1lc63
11:59:59 Chrome Headless 90.0.4430.212 (Linux x86_64) LOG: 'Exception in module-execute in module ext.WikidataPageBanner.positionBanner:'
11:59:59 Chrome Headless 90.0.4430.212 (Linux x86_64) WARN: TypeError: url.indexOf is not a function
11:59:59 TypeError: url.indexOf is not a function
11:59:59     at jQuery.fn.init.jQuery.fn.load (http://localhost:9876/load.php?modules=jquery%7Cmediawiki.base&version=9q0tz:138:28)
11:59:59     at http://localhost:9876/load.php?modules=color-picker%2CdataValues%2CdiffMatchPatch%2Cdompurify%7CdataValues.DataValue%2CTimeValue%2Cvalues%7Cext.WikidataPageBanner.positionBanner%7Cext.articleplaceholder.createArticle%7Cext.centralauth.ForeignApi%7Cext.cite.style%2Cstyles%2CvisualEditor%7Cext.cite.visualEditor.core%2Cdata%7Cext.eventLogging%7Cext.eventLogging.debug%7Cext.guidedTour.lib%2Cstyles%7Cext.guidedTour.lib.internal%7Cext.templateDataGenerator.data%7Cext.uls.common%2Ci18n%2Clanguagenames%2Cmediawiki%2Cmessages%2Cpreferences%2Cwebfonts%7Cext.visualEditor.data%2CmoduleIcons%2CmoduleIndicators%7Cjquery.animateWithEvent%2Cclient%2Ccolor%2Ccookie%2ChighlightText%2Ci18n%2Cinputautoexpand%2ClengthLimit%2CmakeCollapsible%2Cspinner%2Csuggestions%2Ctablesorter%2CtextSelection%2Cthrottle-debounce%2Ctipsy%2Cui%2Culs%2Cvalueview%7Cjquery.event.special.eachchange%7Cjquery.makeCollapsible.styles%7Cjquery.spinner.styles%7Cjquery.tablesorter.styles%7Cjquery.ui.commonssuggester%2Clanguagesuggester%2Csuggester%7Cjquery.uls.data%2Cgrid%7Cjquery.util.getDirectionality%7Cjquery.valueview.Expert%2CExpertExtender%2CExpertStore%7Cjquery.valueview.experts.CommonsMediaType%2CEmptyValue%2CGeoShape%2CGlobeCoordinateInput%2CMonolingualText%2CQuantityInput%2CStringValue%2CTabularData%2CTimeInput%2CUnDeserializableValue%7Cjquery.wikibase.entityselector%2Cwbtooltip%7Cjquery.wikibase.toolbar.styles%7Cmediawiki.ForeignApi%2CForeignStructuredUpload%2CForeignUpload%2CString%2CTitle%2CUpload%2CUri%2Capi%2Ccldr%2Ccookie%2Cexperiments%2Cinspect%2CjqueryMsg%2Clanguage%2CmessagePoster%7Cmediawiki.ForeignApi.core%7Cmediawiki.ForeignStructuredUpload.BookletLayout%7Cmediawiki.Upload.BookletLayout%7Cmediawiki.action.view.redirectPage%7Cmediawiki.diff.styles%7Cmediawiki.editfont.styles%7Cmediawiki.interface.helpers.styles%7Cmediawiki.language.months%2Cnames%2CspecialCharacters%2Ctestdata%7Cmediawiki.libs.guiders%2Cjpegmeta%2Cpluralruleparser%7Cmediawiki.page.gallery.styles%7Cmediawiki.page.ready&version=72fq8:90:739
11:59:59     at http://localhost:9876/load.php?modules=color-picker%2CdataValues%2CdiffMatchPatch%2Cdompurify%7CdataValues.DataValue%2CTimeValue%2Cvalues%7Cext.WikidataPageBanner.positionBanner%7Cext.articleplaceholder.createArticle%7Cext.centralauth.ForeignApi%7Cext.cite.style%2Cstyles%2CvisualEditor%7Cext.cite.visualEditor.core%2Cdata%7Cext.eventLogging%7Cext.eventLogging.debug%7Cext.guidedTour.lib%2Cstyles%7Cext.guidedTour.lib.internal%7Cext.templateDataGenerator.data%7Cext.uls.common%2Ci18n%2Clanguagenames%2Cmediawiki%2Cmessages%2Cpreferences%2Cwebfonts%7Cext.visualEditor.data%2CmoduleIcons%2CmoduleIndicators%7Cjquery.animateWithEvent%2Cclient%2Ccolor%2Ccookie%2ChighlightText%2Ci18n%2Cinputautoexpand%2ClengthLimit%2CmakeCollapsible%2Cspinner%2Csuggestions%2Ctablesorter%2CtextSelection%2Cthrottle-debounce%2Ctipsy%2Cui%2Culs%2Cvalueview%7Cjquery.event.special.eachchange%7Cjquery.makeCollapsible.styles%7Cjquery.spinner.styles%7Cjquery.tablesorter.styles%7Cjquery.ui.commonssuggester%2Clanguagesuggester%2Csuggester%7Cjquery.uls.data%2Cgrid%7Cjquery.util.getDirectionality%7Cjquery.valueview.Expert%2CExpertExtender%2CExpertStore%7Cjquery.valueview.experts.CommonsMediaType%2CEmptyValue%2CGeoShape%2CGlobeCoordinateInput%2CMonolingualText%2CQuantityInput%2CStringValue%2CTabularData%2CTimeInput%2CUnDeserializableValue%7Cjquery.wikibase.entityselector%2Cwbtooltip%7Cjquery.wikibase.toolbar.styles%7Cmediawiki.ForeignApi%2CForeignStructuredUpload%2CForeignUpload%2CString%2CTitle%2CUpload%2CUri%2Capi%2Ccldr%2Ccookie%2Cexperiments%2Cinspect%2CjqueryMsg%2Clanguage%2CmessagePoster%7Cmediawiki.ForeignApi.core%7Cmediawiki.ForeignStructuredUpload.BookletLayout%7Cmediawiki.Upload.BookletLayout%7Cmediawiki.action.view.redirectPage%7Cmediawiki.diff.styles%7Cmediawiki.editfont.styles%7Cmediawiki.interface.helpers.styles%7Cmediawiki.language.months%2Cnames%2CspecialCharacters%2Ctestdata%7Cmediawiki.libs.guiders%2Cjpegmeta%2Cpluralruleparser%7Cmediawiki.page.gallery.styles%7Cmediawiki.page.ready&version=72fq8:91:33
11:59:59     at runScript (http://127.0.0.1:9412//index.php?title=Special:JavaScriptTest/qunit/export:12:745)
11:59:59     at execute (http://127.0.0.1:9412//index.php?title=Special:JavaScriptTest/qunit/export:14:337)
11:59:59     at doPropagation (http://127.0.0.1:9412//index.php?title=Special:JavaScriptTest/qunit/export:6:488)
11:59:59 Chrome Headless 90.0.4430.212 (Linux x86_64) ERROR
11:59:59   Script error.
11:59:59   at :0:0
11:59:59 14 08 2021 09:59:59.754:DEBUG [Chrome Headless 90.0.4430.212 (Linux x86_64)]: CONFIGURING -> CONNECTED
11:59:59 14 08 2021 09:59:59.756:DEBUG [launcher]: CAPTURED -> BEING_KILLED
11:59:59 14 08 2021 09:59:59.757:DEBUG [launcher]: BEING_KILLED -> BEING_FORCE_KILLED
11:59:59 14 08 2021 09:59:59.757:DEBUG [Chrome Headless 90.0.4430.212 (Linux x86_64)]: CONNECTED -> DISCONNECTED

(Noticed on this nonempty change by @Samwilson.)

This might have something to do with something done in T280944: Phase out jQuery Migrate v3

Acceptance criteria 🏕️🌟(18 August 2021)

  • CI is green (test passes) on master

Event Timeline

We should make sure that this extension also covered by T285049

Addshore triaged this task as Medium priority.Aug 18 2021, 8:34 AM
Addshore set the point value for this task to 5.

Change 715044 had a related patch set uploaded (by Lucas Werkmeister (WMDE); author: Lucas Werkmeister (WMDE)):

[mediawiki/extensions/WikidataPageBanner@master] Use $.on( 'load' ) instead of $.load()

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

Lucas_Werkmeister_WMDE added a subscriber: Addshore.

This might have something to do with something done in T280944: Phase out jQuery Migrate v3

Pretty sure @Addshore’s guess is correct, let’s see what CI says about my patch.

We should make sure that this extension also covered by T285049

Hm, maybe not? According to mediawiki.org, this isn’t actually “our” extension, but “belongs” to the Reading Web team. git shortlog also agrees with that. I just added this task to [DEPRECATED] wdwb-tech because I was misled by the “Wikidata” in the name ^^

I guess we can still review and merge the fix, since it’s not too complicated.

Change 715044 merged by jenkins-bot:

[mediawiki/extensions/WikidataPageBanner@master] Use $.on( 'load' ) instead of $.load()

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