Page MenuHomePhabricator

PHP Deprecated: preg_match(): Passing null to parameter #2 ($subject) of type string is deprecated
Closed, ResolvedPublicPRODUCTION ERROR

Description

Error
normalized_message
[{reqId}] {exception_url}   PHP Deprecated: preg_match(): Passing null to parameter #2 ($subject) of type string is deprecated
FrameLocationCall
from/srv/mediawiki/php-1.44.0-wmf.13/extensions/Math/src/SpecialMathWikibase.php(157)
#0[internal function]MWExceptionHandler::handleError(int, string, string, int)
#1/srv/mediawiki/php-1.44.0-wmf.13/extensions/Math/src/SpecialMathWikibase.php(157)preg_match(string, null, null)
#2/srv/mediawiki/php-1.44.0-wmf.13/extensions/Math/src/SpecialMathWikibase.php(69)MediaWiki\Extension\Math\SpecialMathWikibase->buildPageRepresentation(MediaWiki\Extension\Math\MathWikibaseInfo, string, MediaWiki\Output\OutputPage)
#3/srv/mediawiki/php-1.44.0-wmf.13/includes/specialpage/SpecialPage.php(729)MediaWiki\Extension\Math\SpecialMathWikibase->execute(null)
#4/srv/mediawiki/php-1.44.0-wmf.13/includes/specialpage/SpecialPageFactory.php(1735)MediaWiki\SpecialPage\SpecialPage->run(null)
#5/srv/mediawiki/php-1.44.0-wmf.13/includes/actions/ActionEntryPoint.php(503)MediaWiki\SpecialPage\SpecialPageFactory->executePath(string, MediaWiki\Context\RequestContext)
#6/srv/mediawiki/php-1.44.0-wmf.13/includes/actions/ActionEntryPoint.php(145)MediaWiki\Actions\ActionEntryPoint->performRequest()
#7/srv/mediawiki/php-1.44.0-wmf.13/includes/MediaWikiEntryPoint.php(202)MediaWiki\Actions\ActionEntryPoint->execute()
#8/srv/mediawiki/php-1.44.0-wmf.13/index.php(58)MediaWiki\MediaWikiEntryPoint->run()
#9/srv/mediawiki/w/index.php(3)require(string)
#10{main}
Impact
Notes

Event Timeline

In MathWikibaseInfo:

	/**
	 * @return string description
	 */
	public function getDescription() {
		return $this->description;
	}

This is incorrect, as the description is by default null, and not initialised in the constructor...

Change #1115408 had a related patch set uploaded (by Reedy; author: Reedy):

[mediawiki/extensions/Math@master] SpecialMathWikibase: Null-coalescence getDescription() call

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

Change #1115408 merged by jenkins-bot:

[mediawiki/extensions/Math@master] SpecialMathWikibase: Null-coalescence getDescription() call

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

Change #1115512 had a related patch set uploaded (by Reedy; author: Reedy):

[mediawiki/extensions/Math@REL1_43] SpecialMathWikibase: Null-coalescence getDescription() call

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

Change #1115513 had a related patch set uploaded (by Reedy; author: Reedy):

[mediawiki/extensions/Math@REL1_42] SpecialMathWikibase: Null-coalescence getDescription() call

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

Change #1115514 had a related patch set uploaded (by Reedy; author: Reedy):

[mediawiki/extensions/Math@REL1_39] SpecialMathWikibase: Null-coalescence getDescription() call

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

Change #1115514 merged by jenkins-bot:

[mediawiki/extensions/Math@REL1_39] SpecialMathWikibase: Null-coalescence getDescription() call

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

Change #1115513 merged by jenkins-bot:

[mediawiki/extensions/Math@REL1_42] SpecialMathWikibase: Null-coalescence getDescription() call

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

Change #1115512 merged by jenkins-bot:

[mediawiki/extensions/Math@REL1_43] SpecialMathWikibase: Null-coalescence getDescription() call

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

Change #1116784 had a related patch set uploaded (by Reedy; author: Reedy):

[mediawiki/extensions/Math@wmf/1.44.0-wmf.14] SpecialMathWikibase: Null-coalescence getDescription() call

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

Change #1116784 merged by jenkins-bot:

[mediawiki/extensions/Math@wmf/1.44.0-wmf.14] SpecialMathWikibase: Null-coalescence getDescription() call

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

Mentioned in SAL (#wikimedia-operations) [2025-02-03T13:27:08Z] <reedy@deploy2002> Started scap sync-world: Backport for [[gerrit:1116783|Add missing array_values for PHP 7 compatibility (T385255)]], [[gerrit:1116784|SpecialMathWikibase: Null-coalescence getDescription() call (T385170)]], [[gerrit:1116785|SpecialMathWikibase: Null-coalescence $par (T385269)]], [[gerrit:1116788|ApiQueryContentTranslationSuggestions: Set default value for to and from parameters (T385267)]]

Mentioned in SAL (#wikimedia-operations) [2025-02-03T13:34:08Z] <reedy@deploy2002> reedy: Backport for [[gerrit:1116783|Add missing array_values for PHP 7 compatibility (T385255)]], [[gerrit:1116784|SpecialMathWikibase: Null-coalescence getDescription() call (T385170)]], [[gerrit:1116785|SpecialMathWikibase: Null-coalescence $par (T385269)]], [[gerrit:1116788|ApiQueryContentTranslationSuggestions: Set default value for to and from parameters (T385267)]] synced to the testservers (h

Mentioned in SAL (#wikimedia-operations) [2025-02-03T13:43:52Z] <reedy@deploy2002> Finished scap sync-world: Backport for [[gerrit:1116783|Add missing array_values for PHP 7 compatibility (T385255)]], [[gerrit:1116784|SpecialMathWikibase: Null-coalescence getDescription() call (T385170)]], [[gerrit:1116785|SpecialMathWikibase: Null-coalescence $par (T385269)]], [[gerrit:1116788|ApiQueryContentTranslationSuggestions: Set default value for to and from parameters (T385267)]] (duration