Page MenuHomePhabricator

Revision 105215021 belongs to page ID 2442048, the provided Title object belongs to page ID 8437055
Closed, ResolvedPublicPRODUCTION ERROR

Description

Error

MediaWiki version: 1.36.0-wmf.1

message
Revision 105215021 belongs to page ID 2442048, the provided Title object belongs to page ID 8437055

Impact

There are some dozens of these occuring in production. Not huge numbers, but enough to make me worried, as train conductor. Would appreciate it if someone who understands the code took a look.

Notes

Details

Request ID
9ff606e0-46c6-450b-b3b6-cbbbb0792eda
Request URL
https://ru.wikipedia.org/w/index.php?title=%D0%A1%D0%BB%D1%83%D0%B6%D0%B5%D0%B1%D0%BD%D0%B0%D1%8F:%D0%9F%D0%B5%D1%80%D0%B5%D0%B8%D0%BC%D0%B5%D0%BD%D0%BE%D0%B2%D0%B0%D1%82%D1%8C_%D1%81%D1%82%D1%80%D0%B0%D0%BD%D0%B8%D1%86%D1%83&action=submit
Stack Trace
exception.trace
#0 /srv/mediawiki/php-1.36.0-wmf.1/includes/Revision/RevisionStore.php(2922): MediaWiki\Revision\RevisionStore->ensureRevisionRowMatchesTitle(stdClass, Title, array)
#1 /srv/mediawiki/php-1.36.0-wmf.1/includes/parser/Parser.php(3519): MediaWiki\Revision\RevisionStore->getKnownCurrentRevision(Title)
#2 /srv/mediawiki/php-1.36.0-wmf.1/includes/parser/Parser.php(3464): Parser->statelessFetchRevisionRecord(Title, Parser)
#3 /srv/mediawiki/php-1.36.0-wmf.1/extensions/Scribunto/includes/engines/LuaCommon/TitleLibrary.php(292): Parser->fetchCurrentRevisionRecordOfTitle(Title)
#4 /srv/mediawiki/php-1.36.0-wmf.1/extensions/Scribunto/includes/engines/LuaCommon/TitleLibrary.php(326): Scribunto_LuaTitleLibrary->getContentInternal(string)
#5 /srv/mediawiki/php-1.36.0-wmf.1/extensions/Scribunto/includes/engines/LuaSandbox/LuaSandboxCallback.php(26): Scribunto_LuaTitleLibrary->getContent(string)
#6 [internal function]: Scribunto_LuaSandboxCallback->__call(string, array)
#7 /srv/mediawiki/php-1.36.0-wmf.1/extensions/Scribunto/includes/engines/LuaSandbox/LuaSandboxInterpreter.php(113): LuaSandboxFunction->call(LuaSandboxFunction)
#8 /srv/mediawiki/php-1.36.0-wmf.1/extensions/Scribunto/includes/engines/LuaCommon/LuaEngine.php(291): Scribunto_LuaSandboxInterpreter->callFunction(LuaSandboxFunction, LuaSandboxFunction)
#9 /srv/mediawiki/php-1.36.0-wmf.1/extensions/Scribunto/includes/engines/LuaCommon/LuaModule.php(68): Scribunto_LuaEngine->executeFunctionChunk(LuaSandboxFunction, PPTemplateFrame_Hash)
#10 /srv/mediawiki/php-1.36.0-wmf.1/extensions/Scribunto/includes/common/Hooks.php(128): Scribunto_LuaModule->invoke(string, PPTemplateFrame_Hash)
#11 /srv/mediawiki/php-1.36.0-wmf.1/includes/parser/Parser.php(3340): ScribuntoHooks::invokeHook(Parser, PPTemplateFrame_Hash, array)
#12 /srv/mediawiki/php-1.36.0-wmf.1/includes/parser/Parser.php(3047): Parser->callParserFunction(PPTemplateFrame_Hash, string, array)
#13 /srv/mediawiki/php-1.36.0-wmf.1/includes/parser/PPFrame_Hash.php(253): Parser->braceSubstitution(array, PPTemplateFrame_Hash)
#14 /srv/mediawiki/php-1.36.0-wmf.1/includes/parser/PPTemplateFrame_Hash.php(89): PPFrame_Hash->expand(PPNode_Hash_Tree, integer)
#15 /srv/mediawiki/php-1.36.0-wmf.1/includes/parser/Parser.php(3222): PPTemplateFrame_Hash->cachedExpand(string, PPNode_Hash_Tree)
#16 /srv/mediawiki/php-1.36.0-wmf.1/includes/parser/PPFrame_Hash.php(253): Parser->braceSubstitution(array, PPFrame_Hash)
#17 /srv/mediawiki/php-1.36.0-wmf.1/includes/parser/Parser.php(2887): PPFrame_Hash->expand(PPNode_Hash_Tree, integer)
#18 /srv/mediawiki/php-1.36.0-wmf.1/includes/parser/Parser.php(1556): Parser->replaceVariables(string)
#19 /srv/mediawiki/php-1.36.0-wmf.1/includes/parser/Parser.php(651): Parser->internalParse(string)
#20 /srv/mediawiki/php-1.36.0-wmf.1/includes/content/WikitextContent.php(374): Parser->parse(string, Title, ParserOptions, boolean, boolean, NULL)
#21 /srv/mediawiki/php-1.36.0-wmf.1/includes/content/AbstractContent.php(590): WikitextContent->fillParserOutput(Title, NULL, ParserOptions, boolean, ParserOutput)
#22 /srv/mediawiki/php-1.36.0-wmf.1/extensions/PageImages/includes/Hooks/LinksUpdateHookHandler.php(78): AbstractContent->getParserOutput(Title)
#23 /srv/mediawiki/php-1.36.0-wmf.1/extensions/PageImages/includes/Hooks/LinksUpdateHookHandler.php(93): PageImages\Hooks\LinksUpdateHookHandler->getPageImageCandidates(LinksUpdate)
#24 /srv/mediawiki/php-1.36.0-wmf.1/extensions/PageImages/includes/Hooks/LinksUpdateHookHandler.php(36): PageImages\Hooks\LinksUpdateHookHandler->doLinksUpdate(LinksUpdate)
#25 /srv/mediawiki/php-1.36.0-wmf.1/includes/HookContainer/HookContainer.php(320): PageImages\Hooks\LinksUpdateHookHandler::onLinksUpdate(LinksUpdate)
#26 /srv/mediawiki/php-1.36.0-wmf.1/includes/HookContainer/HookContainer.php(131): MediaWiki\HookContainer\HookContainer->callLegacyHook(string, array, array, array)
#27 /srv/mediawiki/php-1.36.0-wmf.1/includes/HookContainer/HookRunner.php(2364): MediaWiki\HookContainer\HookContainer->run(string, array)
#28 /srv/mediawiki/php-1.36.0-wmf.1/includes/deferred/LinksUpdate.php(193): MediaWiki\HookContainer\HookRunner->onLinksUpdate(LinksUpdate)
#29 /srv/mediawiki/php-1.36.0-wmf.1/includes/deferred/DeferredUpdates.php(467): LinksUpdate->doUpdate()
#30 /srv/mediawiki/php-1.36.0-wmf.1/includes/deferred/RefreshSecondaryDataUpdate.php(101): DeferredUpdates::attemptUpdate(LinksUpdate, Wikimedia\Rdbms\LBFactoryMulti)
#31 /srv/mediawiki/php-1.36.0-wmf.1/includes/deferred/DeferredUpdates.php(467): RefreshSecondaryDataUpdate->doUpdate()
#32 /srv/mediawiki/php-1.36.0-wmf.1/includes/deferred/DeferredUpdates.php(344): DeferredUpdates::attemptUpdate(RefreshSecondaryDataUpdate, Wikimedia\Rdbms\LBFactoryMulti)
#33 /srv/mediawiki/php-1.36.0-wmf.1/includes/deferred/DeferredUpdates.php(278): DeferredUpdates::run(RefreshSecondaryDataUpdate, Wikimedia\Rdbms\LBFactoryMulti, Monolog\Logger, BufferingStatsdDataFactory, string)
#34 /srv/mediawiki/php-1.36.0-wmf.1/includes/deferred/DeferredUpdates.php(194): DeferredUpdates::handleUpdateQueue(array, string, integer)
#35 /srv/mediawiki/php-1.36.0-wmf.1/includes/MediaWiki.php(1113): DeferredUpdates::doUpdates(string)
#36 /srv/mediawiki/php-1.36.0-wmf.1/includes/MediaWiki.php(849): MediaWiki->restInPeace()
#37 /srv/mediawiki/php-1.36.0-wmf.1/includes/MediaWiki.php(861): MediaWiki->{closure}()
#38 /srv/mediawiki/php-1.36.0-wmf.1/includes/MediaWiki.php(582): MediaWiki->doPostOutputShutdown()
#39 /srv/mediawiki/php-1.36.0-wmf.1/index.php(53): MediaWiki->run()
#40 /srv/mediawiki/php-1.36.0-wmf.1/index.php(46): wfIndexMain()
#41 /srv/mediawiki/w/index.php(3): require(string)
#42 {main}

Event Timeline

Will look at this sometime today if someone doesn't beat me to it. Daniel is out this week. Adding @Pchelolo and @DannyS712 (who have also recently worked on Revision code) and @CCicalese_WMF (who is currently on Platform Team Clinic Duty).

If I'm reading this correctly, the error is occurring in 1.36.0-wmf.1, but 9bd04f784566 didn't hit until 1.36.0-wmf.2. Let me know if I'm not looking at that correctly.

Not that this doesn't need investigated, and I'll continue to look. I'm just thinking 9bd04f784566 is not the cause.

I'm no train log triage expert, so I could be misinterpreting. But looking back over the last couple of months, I'm seeing this in multiple mediawiki versions, and I'm not seeing an enormous spike in recent frequency. Maybe the last few days have been slightly higher, but not by orders of magnitude. So from a train conductor's perspective, I'm not seeing anything worthy of train blocking.

I'm tempted to triage this on Platform Team Clinic Duty as Medium priority. In practice, that means it may float around on the workboard for some time. Let me know if you think this is more urgent.

Debugging note: for whatever reason, the majority seem to be coming from ruwiki. Unsure if this is significant.

From a train blocker point of view it's not urgent, but, speaking as someone on the train conductor rotation, every error message in logstash adds to the friction of the train, and increases the burden of making sure nothing's broken. From that point of view, fixing non-blocker error messages would help make us run the train faster, and more often.

@BPirkle thank you for your analysis, much appreciated.

Hm, I wonder if this might have been a harbinger of T259855: DiscussionTools touched unrelated parts of the page which we didn't notice at the time.

We made a pretty substantial overhaul of this code in wmf.6, being deployed this week, it would be interesting to know if the log message goes away.

(At the very least the stack trace should change.)

Change 641198 had a related patch set uploaded (by Ammarpad; owner: Ammarpad):
[mediawiki/core@master] Add maintenance script to delete corrupted pages

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

Still seeing these in 1.36.0-wmf.34, somewhere around 1 an hour.

Change 683242 had a related patch set uploaded (by Daniel Kinzler; author: Daniel Kinzler):

[mediawiki/core@master] RevisionStore: don't die on mismatching Titles

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

Change 683242 merged by jenkins-bot:

[mediawiki/core@master] RevisionStore: don't die on mismatching Titles

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

Krinkle assigned this task to daniel.
Krinkle subscribed.

Confirmed in Logstash by searching for message:"the provided Title object belongs to page ID" on the mediawiki-errors dashboard over the last 90 days. There are no entries after May 7th, which is the week after the above patch landed.

Note that the original error has not been resolved, it is now just logged in a non-fatal way. I filed a new ticket, see T284904: Encountered mismatching Title object (see T259022, T268910, T279832, T263340).

Change 701703 had a related patch set uploaded (by Tim Starling; author: Tim Starling):

[mediawiki/core@master] Improvements to fixMergeHistoryCorruption.php

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