Page MenuHomePhabricator

Special:AbuseLog InvalidArgumentException when logged out
Closed, ResolvedPublicBUG REPORT

Description

Steps to replicate the issue (include links if applicable):

  • Visit Special:AbuseLog when logged out

What happens?:

[2024-10-23T08:27:34.338096+00:00] exception.ERROR: [92905e0545f0ae814785d7eb] /wiki/Special:AbuseLog   InvalidArgumentException: Scalar parameter must be a string, number, Stringable, or MessageSpecifier; got bool {"exception":"[object] (InvalidArgumentException(code: 0): Scalar parameter must be a string, number, Stringable, or MessageSpecifier; got bool at /srv/mediawiki/tags/2024-10-22_21:45:53/includes/libs/Message/ScalarParam.php:50)
[stacktrace]
#0 /srv/mediawiki/tags/2024-10-22_21:45:53/includes/Message/Message.php(1210): Wikimedia\\Message\\ScalarParam->__construct()
#1 /srv/mediawiki/tags/2024-10-22_21:45:53/includes/Message/Message.php(601): MediaWiki\\Message\\Message::rawParam()
#2 /srv/mediawiki/tags/2024-10-22_21:45:53/extensions/AbuseFilter/includes/Pager/AbuseLogPager.php(265): MediaWiki\\Message\\Message->rawParams()
#3 /srv/mediawiki/tags/2024-10-22_21:45:53/extensions/AbuseFilter/includes/Pager/AbuseLogPager.php(84): MediaWiki\\Extension\\AbuseFilter\\Pager\\AbuseLogPager->doFormatRow()
#4 /srv/mediawiki/tags/2024-10-22_21:45:53/includes/pager/ReverseChronologicalPager.php(134): MediaWiki\\Extension\\AbuseFilter\\Pager\\AbuseLogPager->formatRow()
#5 /srv/mediawiki/tags/2024-10-22_21:45:53/includes/pager/IndexPager.php(601): MediaWiki\\Pager\\ReverseChronologicalPager->getRow()
#6 /srv/mediawiki/tags/2024-10-22_21:45:53/extensions/AbuseFilter/includes/Special/SpecialAbuseLog.php(673): MediaWiki\\Pager\\IndexPager->getBody()
#7 /srv/mediawiki/tags/2024-10-22_21:45:53/extensions/AbuseFilter/includes/Special/SpecialAbuseLog.php(248): MediaWiki\\Extension\\AbuseFilter\\Special\\SpecialAbuseLog->showList()
#8 /srv/mediawiki/tags/2024-10-22_21:45:53/includes/specialpage/SpecialPage.php(728): MediaWiki\\Extension\\AbuseFilter\\Special\\SpecialAbuseLog->execute()
#9 /srv/mediawiki/tags/2024-10-22_21:45:53/includes/specialpage/SpecialPageFactory.php(1724): MediaWiki\\SpecialPage\\SpecialPage->run()
#10 /srv/mediawiki/tags/2024-10-22_21:45:53/includes/actions/ActionEntryPoint.php(504): MediaWiki\\SpecialPage\\SpecialPageFactory->executePath()
#11 /srv/mediawiki/tags/2024-10-22_21:45:53/includes/actions/ActionEntryPoint.php(146): MediaWiki\\Actions\\ActionEntryPoint->performRequest()
#12 /srv/mediawiki/tags/2024-10-22_21:45:53/includes/MediaWikiEntryPoint.php(200): MediaWiki\\Actions\\ActionEntryPoint->execute()
#13 /srv/mediawiki/tags/2024-10-22_21:45:53/index.php(58): MediaWiki\\MediaWikiEntryPoint->run()
#14 {main}
","exception_url":"/wiki/Special:AbuseLog","reqId":"92905e0545f0ae814785d7eb","caught_by":"entrypoint"} []

What should have happened instead?:

No exception

Software version (on Special:Version page; skip for WMF-hosted wikis like Wikipedia):

Other information (browser name/version, screenshots, etc.):

Event Timeline

Also happens in WMF production:

Error
normalized_message
[{reqId}] {exception_url}   InvalidArgumentException: Scalar parameter must be a string, number, Stringable, or MessageSpecifier; got bool
FrameLocationCall
from/srv/mediawiki/php-1.43.0-wmf.28/includes/libs/Message/ScalarParam.php(50)
#0/srv/mediawiki/php-1.43.0-wmf.28/includes/Message/Message.php(1210)Wikimedia\Message\ScalarParam->__construct(string, bool)
#1/srv/mediawiki/php-1.43.0-wmf.28/includes/Message/Message.php(601)MediaWiki\Message\Message::rawParam(bool)
#2/srv/mediawiki/php-1.43.0-wmf.28/extensions/AbuseFilter/includes/Pager/AbuseLogPager.php(266)MediaWiki\Message\Message->rawParams(string, string, string, string, string, string, bool)
#3/srv/mediawiki/php-1.43.0-wmf.28/extensions/AbuseFilter/includes/Pager/AbuseLogPager.php(84)MediaWiki\Extension\AbuseFilter\Pager\AbuseLogPager->doFormatRow(stdClass)
#4/srv/mediawiki/php-1.43.0-wmf.28/includes/pager/ReverseChronologicalPager.php(134)MediaWiki\Extension\AbuseFilter\Pager\AbuseLogPager->formatRow(stdClass)
#5/srv/mediawiki/php-1.43.0-wmf.28/includes/pager/IndexPager.php(601)MediaWiki\Pager\ReverseChronologicalPager->getRow(stdClass)
#6/srv/mediawiki/php-1.43.0-wmf.28/extensions/AbuseFilter/includes/Special/SpecialAbuseLog.php(673)MediaWiki\Pager\IndexPager->getBody()
#7/srv/mediawiki/php-1.43.0-wmf.28/extensions/AbuseFilter/includes/Special/SpecialAbuseLog.php(248)MediaWiki\Extension\AbuseFilter\Special\SpecialAbuseLog->showList()
#8/srv/mediawiki/php-1.43.0-wmf.28/includes/specialpage/SpecialPage.php(728)MediaWiki\Extension\AbuseFilter\Special\SpecialAbuseLog->execute(null)
#9/srv/mediawiki/php-1.43.0-wmf.28/includes/specialpage/SpecialPageFactory.php(1724)MediaWiki\SpecialPage\SpecialPage->run(null)
#10/srv/mediawiki/php-1.43.0-wmf.28/includes/actions/ActionEntryPoint.php(504)MediaWiki\SpecialPage\SpecialPageFactory->executePath(string, MediaWiki\Context\RequestContext)
#11/srv/mediawiki/php-1.43.0-wmf.28/includes/actions/ActionEntryPoint.php(146)MediaWiki\Actions\ActionEntryPoint->performRequest()
#12/srv/mediawiki/php-1.43.0-wmf.28/includes/MediaWikiEntryPoint.php(200)MediaWiki\Actions\ActionEntryPoint->execute()
#13/srv/mediawiki/php-1.43.0-wmf.28/index.php(58)MediaWiki\MediaWikiEntryPoint->run()
#14/srv/mediawiki/w/index.php(3)require(string)
#15{main}

Change #1082499 had a related patch set uploaded (by Bartosz Dziewoński; author: Bartosz Dziewoński):

[mediawiki/extensions/AbuseFilter@master] AbuseLogPager: Fix passing `false` as message parameter

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

I can't reproduce locally, but $diffLink in that code is initialized to false, so this should fix it. I think this is a pre-existing bug, and the stricter checks in my Message class changes just revealed it.

Krinkle subscribed.

Tagging for visiblity. Fall out from the fix of old tech debt and developer usability at T358779.

Change #1082499 merged by jenkins-bot:

[mediawiki/extensions/AbuseFilter@master] AbuseLogPager: Fix passing `false` as message parameter

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

Change #1082813 had a related patch set uploaded (by Ahmon Dancy; author: Bartosz Dziewoński):

[mediawiki/extensions/AbuseFilter@wmf/1.43.0-wmf.28] AbuseLogPager: Fix passing `false` as message parameter

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

Change #1082813 merged by jenkins-bot:

[mediawiki/extensions/AbuseFilter@wmf/1.43.0-wmf.28] AbuseLogPager: Fix passing `false` as message parameter

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

Mentioned in SAL (#wikimedia-operations) [2024-10-24T17:06:38Z] <dancy@deploy2002> Started scap sync-world: Backport for [[gerrit:1082813|AbuseLogPager: Fix passing false as message parameter (T377917)]]

Mentioned in SAL (#wikimedia-operations) [2024-10-24T17:09:22Z] <dancy@deploy2002> dancy: Backport for [[gerrit:1082813|AbuseLogPager: Fix passing false as message parameter (T377917)]] synced to the testservers (https://wikitech.wikimedia.org/wiki/Mwdebug)

Mentioned in SAL (#wikimedia-operations) [2024-10-24T17:13:57Z] <dancy@deploy2002> Finished scap sync-world: Backport for [[gerrit:1082813|AbuseLogPager: Fix passing false as message parameter (T377917)]] (duration: 07m 18s)

Change #1083372 had a related patch set uploaded (by Bartosz Dziewoński; author: Bartosz Dziewoński):

[mediawiki/extensions/AbuseFilter@REL1_43] AbuseLogPager: Fix passing `false` as message parameter

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

Change #1083372 merged by jenkins-bot:

[mediawiki/extensions/AbuseFilter@REL1_43] AbuseLogPager: Fix passing `false` as message parameter

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