Page MenuHomePhabricator

LanguageKk_cyrl->lastLetter: PHP Notice: Undefined offset: -1
Closed, ResolvedPublicPRODUCTION ERROR

Description

Error

MediaWiki version: 1.36.0-wmf.34

message
PHP Notice: Undefined offset: -1

Impact

Unclear if any impact to user. Warnings trigger on reloading URL (see this reqID in logstash for specific page).

Notes

2 of these in last ~4 hours.

Details

Request ID
YFJHuTYuNrQJdIjSR1KOvQAAAIU
Request URL
https://kk.wikipedia.org/wiki/[user]/[subpage]
Stack Trace
exception.trace
from /srv/mediawiki/php-1.36.0-wmf.34/languages/classes/LanguageKk_cyrl.php(749)
#0 /srv/mediawiki/php-1.36.0-wmf.34/languages/classes/LanguageKk_cyrl.php(749): MWExceptionHandler::handleError(integer, string, string, integer, array)
#1 /srv/mediawiki/php-1.36.0-wmf.34/languages/classes/LanguageKk_cyrl.php(67): LanguageKk_cyrl->lastLetter(string, array)
#2 /srv/mediawiki/php-1.36.0-wmf.34/languages/classes/LanguageKk.php(85): LanguageKk_cyrl->convertGrammarKk_cyrl(string, string)
#3 /srv/mediawiki/php-1.36.0-wmf.34/includes/parser/CoreParserFunctions.php(345): LanguageKk->convertGrammar(string, string)
#4 /srv/mediawiki/php-1.36.0-wmf.34/includes/parser/Parser.php(3357): CoreParserFunctions::grammar(Parser, string)
#5 /srv/mediawiki/php-1.36.0-wmf.34/includes/parser/Parser.php(3042): Parser->callParserFunction(PPFrame_Hash, string, array)
#6 /srv/mediawiki/php-1.36.0-wmf.34/includes/parser/PPFrame_Hash.php(263): Parser->braceSubstitution(array, PPFrame_Hash)
#7 /srv/mediawiki/php-1.36.0-wmf.34/includes/parser/Parser.php(2880): PPFrame_Hash->expand(PPNode_Hash_Tree, integer)
#8 /srv/mediawiki/php-1.36.0-wmf.34/includes/parser/Parser.php(1560): Parser->replaceVariables(string)
#9 /srv/mediawiki/php-1.36.0-wmf.34/includes/parser/Parser.php(653): Parser->internalParse(string)
#10 /srv/mediawiki/php-1.36.0-wmf.34/includes/content/WikitextContent.php(375): Parser->parse(string, Title, ParserOptions, boolean, boolean, integer)
#11 /srv/mediawiki/php-1.36.0-wmf.34/includes/content/AbstractContent.php(591): WikitextContent->fillParserOutput(Title, integer, ParserOptions, boolean, ParserOutput)
#12 /srv/mediawiki/php-1.36.0-wmf.34/includes/Revision/RenderedRevision.php(266): AbstractContent->getParserOutput(Title, integer, ParserOptions, boolean)
#13 /srv/mediawiki/php-1.36.0-wmf.34/includes/Revision/RenderedRevision.php(235): MediaWiki\Revision\RenderedRevision->getSlotParserOutputUncached(WikitextContent, boolean)
#14 /srv/mediawiki/php-1.36.0-wmf.34/includes/Revision/RevisionRenderer.php(215): MediaWiki\Revision\RenderedRevision->getSlotParserOutput(string, array)
#15 /srv/mediawiki/php-1.36.0-wmf.34/includes/Revision/RevisionRenderer.php(152): MediaWiki\Revision\RevisionRenderer->combineSlotOutput(MediaWiki\Revision\RenderedRevision, array)
#16 [internal function]: MediaWiki\Revision\RevisionRenderer->MediaWiki\Revision\{closure}(MediaWiki\Revision\RenderedRevision, array)
#17 /srv/mediawiki/php-1.36.0-wmf.34/includes/Revision/RenderedRevision.php(197): call_user_func(Closure, MediaWiki\Revision\RenderedRevision, array)
#18 /srv/mediawiki/php-1.36.0-wmf.34/includes/poolcounter/PoolWorkArticleView.php(137): MediaWiki\Revision\RenderedRevision->getRevisionParserOutput()
#19 /srv/mediawiki/php-1.36.0-wmf.34/includes/poolcounter/PoolCounterWork.php(162): PoolWorkArticleView->doWork()
#20 /srv/mediawiki/php-1.36.0-wmf.34/includes/page/ParserOutputAccess.php(260): PoolCounterWork->execute()
#21 /srv/mediawiki/php-1.36.0-wmf.34/includes/page/Article.php(750): MediaWiki\Page\ParserOutputAccess->getParserOutput(WikiPage, ParserOptions, MediaWiki\Revision\RevisionStoreCacheRecord, integer)
#22 /srv/mediawiki/php-1.36.0-wmf.34/includes/page/Article.php(563): Article->generateContentOutput(User, ParserOptions, integer, OutputPage, array)
#23 /srv/mediawiki/php-1.36.0-wmf.34/includes/actions/ViewAction.php(74): Article->view()
#24 /srv/mediawiki/php-1.36.0-wmf.34/includes/MediaWiki.php(531): ViewAction->show()
#25 /srv/mediawiki/php-1.36.0-wmf.34/includes/MediaWiki.php(315): MediaWiki->performAction(Article, Title)
#26 /srv/mediawiki/php-1.36.0-wmf.34/includes/MediaWiki.php(925): MediaWiki->performRequest()
#27 /srv/mediawiki/php-1.36.0-wmf.34/includes/MediaWiki.php(547): MediaWiki->main()
#28 /srv/mediawiki/php-1.36.0-wmf.34/index.php(53): MediaWiki->run()
#29 /srv/mediawiki/php-1.36.0-wmf.34/index.php(46): wfIndexMain()
#30 /srv/mediawiki/w/index.php(3): require(string)
#31 {main}

Event Timeline

I believe, an empty string is being passed to {{GRAMMAR:}} magic word as the word to transform on whatever page is that

Change 673231 had a related patch set uploaded (by Ammarpad; owner: Ammarpad):
[mediawiki/core@master] LanguageKk: Guard against passing nonsense to {{grammar:}} magic word

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

Change 673231 merged by jenkins-bot:
[mediawiki/core@master] LanguageKk: Guard against passing empty string to {{grammar}}

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

Ammarpad claimed this task.