Page MenuHomePhabricator

TypeError: Unsupported operand types: array + null (LiquidThreads)
Closed, ResolvedPublicPRODUCTION ERROR

Description

Error
  • service.version: 1.46.0-wmf.15
  • timestamp: 2026-02-10T09:18:55.562Z
  • labels.phpversion: 8.3.30
  • trace.id: ee7ae674-c974-4d6b-ab10-780ed2083bce
  • Find trace.id in Logstash
labels.normalized_message
[{reqId}] {exception_url}   TypeError: Unsupported operand types: array + null
FrameLocationCall
from/srv/mediawiki/php-1.46.0-wmf.15/extensions/LiquidThreads/includes/Pages/ThreadPermalinkView.php(41)
#0/srv/mediawiki/php-1.46.0-wmf.15/extensions/LiquidThreads/includes/Pages/ThreadPermalinkView.php(13)ThreadPermalinkView::customizeThreadNavigation(MediaWiki\Skins\Vector\SkinVector22, array, IndividualThreadHistoryView)
#1/srv/mediawiki/php-1.46.0-wmf.15/extensions/LiquidThreads/includes/Pages/IndividualThreadHistoryView.php(11)ThreadPermalinkView->customizeNavigation(MediaWiki\Skins\Vector\SkinVector22, array)
#2/srv/mediawiki/php-1.46.0-wmf.15/extensions/LiquidThreads/includes/LqtDispatch.php(247)IndividualThreadHistoryView->customizeNavigation(MediaWiki\Skins\Vector\SkinVector22, array)
#3/srv/mediawiki/php-1.46.0-wmf.15/includes/HookContainer/HookContainer.php(135)LqtDispatch::onSkinTemplateNavigation(MediaWiki\Skins\Vector\SkinVector22, array)
#4/srv/mediawiki/php-1.46.0-wmf.15/includes/HookContainer/HookRunner.php(4066)MediaWiki\HookContainer\HookContainer->run(string, array, array)
#5/srv/mediawiki/php-1.46.0-wmf.15/includes/Skin/SkinTemplate.php(1010)MediaWiki\HookContainer\HookRunner->onSkinTemplateNavigation__Universal(MediaWiki\Skins\Vector\SkinVector22, array)
#6/srv/mediawiki/php-1.46.0-wmf.15/skins/Vector/includes/SkinVector22.php(53)MediaWiki\Skin\SkinTemplate->runOnSkinTemplateNavigationHooks(MediaWiki\Skins\Vector\SkinVector22, array)
#7/srv/mediawiki/php-1.46.0-wmf.15/includes/Skin/SkinTemplate.php(1433)MediaWiki\Skins\Vector\SkinVector22->runOnSkinTemplateNavigationHooks(MediaWiki\Skins\Vector\SkinVector22, array)
#8/srv/mediawiki/php-1.46.0-wmf.15/includes/Skin/SkinTemplate.php(621)MediaWiki\Skin\SkinTemplate->buildContentNavigationUrlsInternal()
#9/srv/mediawiki/php-1.46.0-wmf.15/includes/Skin/SkinTemplate.php(182)MediaWiki\Skin\SkinTemplate->getPortletsTemplateData()
#10/srv/mediawiki/php-1.46.0-wmf.15/includes/Skin/SkinMustache.php(119)MediaWiki\Skin\SkinTemplate->getTemplateData()
#11/srv/mediawiki/php-1.46.0-wmf.15/skins/Vector/includes/SkinVector22.php(328)MediaWiki\Skin\SkinMustache->getTemplateData()
#12/srv/mediawiki/php-1.46.0-wmf.15/includes/Skin/SkinMustache.php(81)MediaWiki\Skins\Vector\SkinVector22->getTemplateData()
#13/srv/mediawiki/php-1.46.0-wmf.15/includes/Skin/SkinTemplate.php(175)MediaWiki\Skin\SkinMustache->generateHTML()
#14/srv/mediawiki/php-1.46.0-wmf.15/includes/Skin/Skin.php(676)MediaWiki\Skin\SkinTemplate->outputPage()
#15/srv/mediawiki/php-1.46.0-wmf.15/includes/Output/OutputPage.php(3307)MediaWiki\Skin\Skin->outputPageFinal(MediaWiki\Output\OutputPage)
#16/srv/mediawiki/php-1.46.0-wmf.15/includes/Actions/ActionEntryPoint.php(161)MediaWiki\Output\OutputPage->output(bool)
#17/srv/mediawiki/php-1.46.0-wmf.15/includes/MediaWikiEntryPoint.php(180)MediaWiki\Actions\ActionEntryPoint->execute()
#18/srv/mediawiki/php-1.46.0-wmf.15/index.php(44)MediaWiki\MediaWikiEntryPoint->run()
#19/srv/mediawiki/w/index.php(3)require(string)
#20{main}
Notes

Started with deploy of 1.45.0-wmf.15 to testwikis/group0. Elevated and constant stream of errors on MediaWiki wiki. I can't see any recent changes to the extension that could explain the backtrace.

The extension has no owners and it's in the process of being archived, so I'm going to ping here people referenced in recent tasks or involved in recent patches. Apologies in advance for any noise.

The error volume is significant and I'm concerned about rolling this out to group1, so I'm marking the bug as a train blocker

Event Timeline

Given this is touching nstabs this might have been affected by the recent changes @Jdlrobson-WMF was shepherding around Vector/other legacy skins and the tabs?

jnuche renamed this task from TypeError: Unsupported operand types: array + null to TypeError: Unsupported operand types: array + null (LiquidThreads).Feb 10 2026, 10:19 AM

The MediaWiki-extensions-LiquidThreads code assumes there is a namespaces element in the $links array provided by the SkinTemplateNavigation hook. The documentation says this is guaranteed. It appears like there was indeed a change in core that broke this guarantee.

The MediaWiki-extensions-LiquidThreads code assumes there is a namespaces element in the $links array provided by the SkinTemplateNavigation hook. The documentation says this is guaranteed. It appears like there was indeed a change in core that broke this guarantee.

Yup, the namespaces menu has been deemed "legacy" by the Reading group for a while now, and this was being deprecated (but not dropped?) in T409774.

Change #1238299 had a related patch set uploaded (by Thiemo Kreuz (WMDE); author: Thiemo Kreuz (WMDE)):

[mediawiki/extensions/LiquidThreads@master] More robust SkinTemplateNavigation hook handler

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

Change #1238299 merged by jenkins-bot:

[mediawiki/extensions/LiquidThreads@master] More robust SkinTemplateNavigation hook handler

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

Change #1238339 had a related patch set uploaded (by Jforrester; author: Thiemo Kreuz (WMDE)):

[mediawiki/extensions/LiquidThreads@wmf/1.46.0-wmf.15] More robust SkinTemplateNavigation hook handler

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

Change #1238339 merged by jenkins-bot:

[mediawiki/extensions/LiquidThreads@wmf/1.46.0-wmf.15] More robust SkinTemplateNavigation hook handler

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

Mentioned in SAL (#wikimedia-operations) [2026-02-10T13:51:06Z] <jforrester@deploy2002> Started scap sync-world: Backport for [[gerrit:1238338|EmailAuthHookHandler: Check if WikimediaEvents loaded before using WikimediaEventsCountryCodeLookup (T416983)]], [[gerrit:1238339|More robust SkinTemplateNavigation hook handler (T416978)]]

Mentioned in SAL (#wikimedia-operations) [2026-02-10T13:53:13Z] <jforrester@deploy2002> jforrester: Backport for [[gerrit:1238338|EmailAuthHookHandler: Check if WikimediaEvents loaded before using WikimediaEventsCountryCodeLookup (T416983)]], [[gerrit:1238339|More robust SkinTemplateNavigation hook handler (T416978)]] synced to the testservers (see https://wikitech.wikimedia.org/wiki/Mwdebug). Changes can now be verified there.

Mentioned in SAL (#wikimedia-operations) [2026-02-10T13:59:01Z] <jforrester@deploy2002> Finished scap sync-world: Backport for [[gerrit:1238338|EmailAuthHookHandler: Check if WikimediaEvents loaded before using WikimediaEventsCountryCodeLookup (T416983)]], [[gerrit:1238339|More robust SkinTemplateNavigation hook handler (T416978)]] (duration: 07m 55s)

Jdforrester-WMF assigned this task to thiemowmde.

Looks like this is now fixed.

@Jdforrester-WMF Thank you so much!

EDIT: And also to @thiemowmde. Apologies for the oversight

Change #1238391 had a related patch set uploaded (by Jdlrobson; author: Jdlrobson):

[mediawiki/extensions/LiquidThreads@master] Restore tabs to Thread history

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

The MediaWiki-extensions-LiquidThreads code assumes there is a namespaces element in the $links array provided by the SkinTemplateNavigation hook. The documentation says this is guaranteed. It appears like there was indeed a change in core that broke this guarantee.

That hook was removed completely in version 1.41.0 (after being deprecated in 1.39.0) so that documentation is very outdated (I added the Outdated template).
The namespaces key was replaced with associated-pages a while back to support work for Special:Contribute and various other special pages.

I've refreshed the documentation on https://www.mediawiki.org/wiki/Manual:Hooks/SkinTemplateNavigation::Universal which was lacking to reflect more recent events so thanks for the ping.

While the merged patch addresses the issue with the warning, it isn't equivalent to the pre-deprecation so I've submitted a follow up ^