Page MenuHomePhabricator

PHP Warning: Undefined array key "request"
Closed, ResolvedPublicPRODUCTION ERROR

Description

Error
normalized_message
[{reqId}] {exception_url}   PHP Warning: Undefined array key "request"
FrameLocationCall
from/srv/mediawiki/php-1.44.0-wmf.24/extensions/WikiLambda/includes/ZErrorFactory.php(524)
#0/srv/mediawiki/php-1.44.0-wmf.24/extensions/WikiLambda/includes/ZErrorFactory.php(524)MediaWiki\Exception\MWExceptionHandler::handleError(int, string, string, int)
#1/srv/mediawiki/php-1.44.0-wmf.24/extensions/WikiLambda/includes/ZErrorFactory.php(598)MediaWiki\Extension\WikiLambda\ZErrorFactory::createZErrorInstance(string, array)
#2/srv/mediawiki/php-1.44.0-wmf.24/extensions/WikiLambda/includes/RESTAPI/FunctionCallHandler.php(679)MediaWiki\Extension\WikiLambda\ZErrorFactory::createApiFailureError(string, string)
#3/srv/mediawiki/php-1.44.0-wmf.24/extensions/WikiLambda/includes/RESTAPI/FunctionCallHandler.php(429)MediaWiki\Extension\WikiLambda\RESTAPI\FunctionCallHandler->makeRequest(string, string)
#4/srv/mediawiki/php-1.44.0-wmf.24/includes/Rest/SimpleHandler.php(40)MediaWiki\Extension\WikiLambda\RESTAPI\FunctionCallHandler->run(string, array, string, string)
#5/srv/mediawiki/php-1.44.0-wmf.24/includes/Rest/Module/Module.php(415)MediaWiki\Rest\SimpleHandler->execute()
#6/srv/mediawiki/php-1.44.0-wmf.24/includes/Rest/Module/Module.php(298)MediaWiki\Rest\Module\Module->executeHandler(MediaWiki\Extension\WikiLambda\RESTAPI\FunctionCallHandler)
#7/srv/mediawiki/php-1.44.0-wmf.24/includes/Rest/Router.php(485)MediaWiki\Rest\Module\Module->execute(string, MediaWiki\Rest\RequestFromGlobals)
#8/srv/mediawiki/php-1.44.0-wmf.24/includes/Rest/Router.php(444)MediaWiki\Rest\Router->doExecute(string, MediaWiki\Rest\RequestFromGlobals)
#9/srv/mediawiki/php-1.44.0-wmf.24/includes/Rest/EntryPoint.php(209)MediaWiki\Rest\Router->execute(MediaWiki\Rest\RequestFromGlobals)
#10/srv/mediawiki/php-1.44.0-wmf.24/includes/MediaWikiEntryPoint.php(202)MediaWiki\Rest\EntryPoint->execute()
#11/srv/mediawiki/php-1.44.0-wmf.24/rest.php(39)MediaWiki\MediaWikiEntryPoint->run()
#12/srv/mediawiki/w/rest.php(3)require(string)
#13{main}
Impact
Notes

Details

Request URL
https://www.wikifunctions.org/w/rest.php/wikifunctions/v0/call/Z21121/NDIuMTk1%7Ca20%7CbWk%7CMQ%7CWjQx%7CWjQx%7CWjEwMDI/en/en
Related Changes in Gerrit:

Event Timeline

Jdforrester-WMF subscribed.

Sorry, I think this is deployment noise (mwdebug has the new code but the jobs call async to this REST route that isn't live yet), but I can't fully reason this code through. The URL now works correctly.

Bad news: Not sure we can meaningfully fix this. Maybe I'm missing something though.

Good news: Shouldn't happen again; this was a one-time deployment gremlin. Maybe?

ZErrorFactory line524:

			case ZErrorTypeRegistry::Z_ERROR_API_FAILURE:
				$zErrorValue[] = new ZQuote( $payload[ 'request'] );
				$zErrorValue[] = $payload['error'];
				break;

I assume 'request' does not exist here

Change #1137310 had a related patch set uploaded (by Daphne Smit; author: Daphne Smit):

[mediawiki/extensions/WikiLambda@master] Fix: PHP Warning: Undefined array key "request"

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

Change #1137310 merged by jenkins-bot:

[mediawiki/extensions/WikiLambda@master] Fix: PHP Warning: Undefined array key "request"

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

Change #1138443 had a related patch set uploaded (by Jforrester; author: Daphne Smit):

[mediawiki/extensions/WikiLambda@wmf/1.44.0-wmf.25] Fix: PHP Warning: Undefined array key "request"

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

Change #1138443 merged by jenkins-bot:

[mediawiki/extensions/WikiLambda@wmf/1.44.0-wmf.25] Fix: PHP Warning: Undefined array key "request"

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

Mentioned in SAL (#wikimedia-operations) [2025-04-28T13:40:52Z] <jforrester@deploy1003> Started scap sync-world: Backport for [[gerrit:1138443|Fix: PHP Warning: Undefined array key "request" (T392026)]], [[gerrit:1139038|Move wgParserMigrationEnableParsoidDiscussionTools and wgParserMigrationEnableParsoidArticlePages to a dblist]], [[gerrit:1139039|manage-dblist: Default all new wikis to parsoidrendered (T376827)]], [[gerrit:1139047|nupwiki: Enable Parsoid mode (T390384)]]

Mentioned in SAL (#wikimedia-operations) [2025-04-28T13:45:24Z] <jforrester@deploy1003> jforrester: Backport for [[gerrit:1138443|Fix: PHP Warning: Undefined array key "request" (T392026)]], [[gerrit:1139038|Move wgParserMigrationEnableParsoidDiscussionTools and wgParserMigrationEnableParsoidArticlePages to a dblist]], [[gerrit:1139039|manage-dblist: Default all new wikis to parsoidrendered (T376827)]], [[gerrit:1139047|nupwiki: Enable Parsoid mode (T390384)]] synced to the testser

Mentioned in SAL (#wikimedia-operations) [2025-04-28T13:52:49Z] <jforrester@deploy1003> Finished scap sync-world: Backport for [[gerrit:1138443|Fix: PHP Warning: Undefined array key "request" (T392026)]], [[gerrit:1139038|Move wgParserMigrationEnableParsoidDiscussionTools and wgParserMigrationEnableParsoidArticlePages to a dblist]], [[gerrit:1139039|manage-dblist: Default all new wikis to parsoidrendered (T376827)]], [[gerrit:1139047|nupwiki: Enable Parsoid mode (T390384)]] (durati

DSantamaria changed the task status from Open to In Progress.Apr 29 2025, 10:35 AM