Page MenuHomePhabricator

LogEventsList.php: PHP Notice: Undefined variable: pageName
Closed, ResolvedPublicPRODUCTION ERROR

Description

Error
normalized_message
[{reqId}] {exception_url}   PHP Notice: Undefined variable: pageName
exception.trace
from /srv/mediawiki/php-1.37.0-wmf.5/includes/logging/LogEventsList.php(770)
#0 /srv/mediawiki/php-1.37.0-wmf.5/includes/logging/LogEventsList.php(770): MWExceptionHandler::handleError(integer, string, string, integer, array)
#1 /srv/mediawiki/php-1.37.0-wmf.5/extensions/CentralAuth/includes/specials/SpecialMultiLock.php(520): LogEventsList::showLogExtract(string, array, string, string, array)
#2 /srv/mediawiki/php-1.37.0-wmf.5/extensions/CentralAuth/includes/specials/SpecialMultiLock.php(106): SpecialMultiLock->showLogExtract()
#3 /srv/mediawiki/php-1.37.0-wmf.5/includes/specialpage/SpecialPage.php(646): SpecialMultiLock->execute(NULL)
#4 /srv/mediawiki/php-1.37.0-wmf.5/includes/specialpage/SpecialPageFactory.php(1396): SpecialPage->run(NULL)
#5 /srv/mediawiki/php-1.37.0-wmf.5/includes/MediaWiki.php(313): MediaWiki\SpecialPage\SpecialPageFactory->executePath(string, RequestContext)
#6 /srv/mediawiki/php-1.37.0-wmf.5/includes/MediaWiki.php(916): MediaWiki->performRequest()
#7 /srv/mediawiki/php-1.37.0-wmf.5/includes/MediaWiki.php(550): MediaWiki->main()
#8 /srv/mediawiki/php-1.37.0-wmf.5/index.php(53): MediaWiki->run()
#9 /srv/mediawiki/php-1.37.0-wmf.5/index.php(46): wfIndexMain()
#10 /srv/mediawiki/w/index.php(3): require(string)
#11 {main}
Notes

16 of these in the last hour. This error is new for wmf.5. There are two variants of the same error message, one occurring at LogEventsList:732

Details

Request URL
https://meta.wikimedia.org/wiki/Special:MultiLock

Event Timeline

dancy renamed this task from PHP Notice: Undefined variable: pageName to LogEventsList.php: PHP Notice: Undefined variable: pageName.May 13 2021, 10:02 PM

Change 690784 had a related patch set uploaded (by Ppchelko; author: Ppchelko):

[mediawiki/core@master] LogEventsList: always define $pageName

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

Change 690784 merged by jenkins-bot:

[mediawiki/core@master] LogEventsList: always define $pageName

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

Change 690808 had a related patch set uploaded (by Jforrester; author: Ppchelko):

[mediawiki/core@wmf/1.37.0-wmf.5] LogEventsList: always define $pageName

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

Change 690784 merged by jenkins-bot:

[mediawiki/core@master] LogEventsList: always define $pageName

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

Issue was introduced in 60734d3b192623 (T278459).

@daniel Perhaps worth a retro to understand why Phan didn't catch this use of conditionally defined variable as being a problem?

Change 690808 merged by jenkins-bot:

[mediawiki/core@wmf/1.37.0-wmf.5] LogEventsList: always define $pageName

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

Mentioned in SAL (#wikimedia-operations) [2021-05-14T03:13:36Z] <tstarling@deploy1002> Synchronized php-1.37.0-wmf.5/includes/logging/LogEventsList.php: fix PHP notice T282834 (duration: 01m 08s)