Page MenuHomePhabricator

Accessing https://www.mediawiki.org/wiki/Talk:Content_translation/Flow returns Fatal exception of type "Flow\Exception\InvalidDataException"
Closed, ResolvedPublicPRODUCTION ERROR

Description

Error
NOTE: Error is not visible in Logstash because of T371586: Flow internal error on frwiki not in logstash.
message
[5f2b574e-94f6-9fc2-a17e-4ddb53f1d495] /wiki/Talk:Content_translation/Flow Flow\Exception\InvalidDataException: Flow workflow is for different page
trace
from /srv/mediawiki/php-1.44.0-wmf.6/extensions/Flow/includes/WorkflowLoaderFactory.php(132)
#0 /srv/mediawiki/php-1.44.0-wmf.6/extensions/Flow/includes/WorkflowLoaderFactory.php(105): Flow\WorkflowLoaderFactory->loadWorkflowById(MediaWiki\Title\Title, Flow\Model\UUID)
#1 /srv/mediawiki/php-1.44.0-wmf.6/extensions/Flow/includes/Actions/FlowAction.php(96): Flow\WorkflowLoaderFactory->createWorkflowLoader(MediaWiki\Title\Title)
#2 /srv/mediawiki/php-1.44.0-wmf.6/extensions/Flow/includes/Actions/ViewAction.php(26): Flow\Actions\FlowAction->showForAction(string, MediaWiki\Output\OutputPage)
#3 /srv/mediawiki/php-1.44.0-wmf.6/extensions/Flow/includes/Actions/FlowAction.php(50): Flow\Actions\ViewAction->showForAction(string)
#4 /srv/mediawiki/php-1.44.0-wmf.6/includes/actions/ActionEntryPoint.php(733): Flow\Actions\FlowAction->show()
#5 /srv/mediawiki/php-1.44.0-wmf.6/includes/actions/ActionEntryPoint.php(510): MediaWiki\Actions\ActionEntryPoint->performAction(Article, MediaWiki\Title\Title)
#6 /srv/mediawiki/php-1.44.0-wmf.6/includes/actions/ActionEntryPoint.php(146): MediaWiki\Actions\ActionEntryPoint->performRequest()
#7 /srv/mediawiki/php-1.44.0-wmf.6/includes/MediaWikiEntryPoint.php(201): MediaWiki\Actions\ActionEntryPoint->execute()
#8 /srv/mediawiki/php-1.44.0-wmf.6/index.php(58): MediaWiki\MediaWikiEntryPoint->run()
#9 /srv/mediawiki/w/index.php(3): require(string)
#10 {main}
Impact

Page is inaccessible to readers. In this case, the error was only present when accessing via the eqiad datacenter.

Notes

This is an instance of T371769: Moving a Flow discussion page can render it inaccessible, as the error happened after @Quiddity moved the page from its previous name (Talk:Content_translation).

Details

Request URL
https://www.mediawiki.org/wiki/Talk:Content_translation/Flow

Event Timeline

Urbanecm_WMF created this task.
Restricted Application added a subscriber: Aklapper. · View Herald Transcript

The error can be reliably reproduced when accessing via an eqiad mwdebug server. The page can be reliably loaded when accessing it via an codfw mwdebug server. For this reason, checks will be made in both DCs.

Database

Flow's database (flowdb.flow_workflow on x1) is updated in both DCs:

Codfw:

wikiadmin2023@10.192.32.162(flowdb)> select * from flow_workflow where workflow_wiki='mediawikiwiki' and workflow_namespace=1 and workflow_title_text='Content_translation/Flow' and workflow_type='discussion'\G
*************************** 1. row ***************************
                   workflow_id: 
                                ʹ9g
                 workflow_wiki: mediawikiwiki
            workflow_namespace: 1
              workflow_page_id: 220123
           workflow_title_text: Content_translation/Flow
                 workflow_name: 
workflow_last_update_timestamp: 20231117202429
              workflow_user_id: NULL
           workflow_lock_state: 0
        workflow_definition_id: NULL
              workflow_user_ip: NULL
            workflow_user_wiki: NULL
                 workflow_type: discussion
1 row in set (0.025 sec)

wikiadmin2023@10.192.32.162(flowdb)>

Eqiad

wikiadmin2023@10.64.16.208(flowdb)> select * from flow_workflow where workflow_wiki='mediawikiwiki' and workflow_namespace=1 and workflow_title_text='Content_translation/Flow' and workflow_type='discussion'\G
*************************** 1. row ***************************
                   workflow_id: ?
                                 ʹ?9?g
                 workflow_wiki: mediawikiwiki
            workflow_namespace: 1
              workflow_page_id: 220123
           workflow_title_text: Content_translation/Flow
                 workflow_name: 
workflow_last_update_timestamp: 20231117202429
              workflow_user_id: NULL
           workflow_lock_state: 0
        workflow_definition_id: NULL
              workflow_user_ip: NULL
            workflow_user_wiki: NULL
                 workflow_type: discussion
1 row in set (0.038 sec)

wikiadmin2023@10.64.16.208(flowdb)>

MediaWiki's database (mediawikiwiki.page) is updated in both DCs:

Codfw

wikiadmin2023@10.192.13.7(mediawikiwiki)> select * from page where page_id=220123\G
*************************** 1. row ***************************
           page_id: 220123
    page_namespace: 1
        page_title: Content_translation/Flow
  page_is_redirect: 0
       page_is_new: 0
       page_random: 0.817258208156
      page_touched: 20241206181225
page_links_updated: 20241206181225
       page_latest: 6890420
          page_len: 1
page_content_model: flow-board
         page_lang: NULL
1 row in set (0.001 sec)

wikiadmin2023@10.192.13.7(mediawikiwiki)>

Eqiad:

wikiadmin2023@10.64.32.82(mediawikiwiki)> select * from page where page_id=220123\G
*************************** 1. row ***************************
           page_id: 220123
    page_namespace: 1
        page_title: Content_translation/Flow
  page_is_redirect: 0
       page_is_new: 0
       page_random: 0.817258208156
      page_touched: 20241206181225
page_links_updated: 20241206181225
       page_latest: 6890420
          page_len: 1
page_content_model: flow-board
         page_lang: NULL
1 row in set (0.001 sec)

wikiadmin2023@10.64.32.82(mediawikiwiki)>
WAN cache

Codfw

Now running eval.php for mediawikiwiki inside pod/mw-debug.codfw.pinkunicorn-6b6d575bf7-8k29v on release pinkunicorn...
> $c = require "$IP/extensions/Flow/container.php";

> $f = $c['factory.loader.workflow']

> $wikipage = \MediaWiki\MediaWikiServices::getInstance()->getWikiPageFactory()->newFromTitle(Title::newFromText('Talk:Content_translation/Flow'))

> $content = $wikipage->getContent()

> $content->getWorkflowId()

> $workflowId = $content->getWorkflowId()

> $storage = $c['storage']

> 

> $workflow = $storage->getStorage('Workflow')->get($workflowId)

> echo $workflow->getArticleTitle()->getPrefixedText()
Talk:Content translation/Flow
>

Eqiad:

Now running eval.php for mediawikiwiki inside pod/mw-debug.eqiad.pinkunicorn-6996b8cd95-54dpk on release pinkunicorn...
> $c = require "$IP/extensions/Flow/container.php";

> $f = $c['factory.loader.workflow']

> $wikipage = \MediaWiki\MediaWikiServices::getInstance()->getWikiPageFactory()->newFromTitle(Title::newFromText('Talk:Content_translation/Flow'))

> $content = $wikipage->getContent()

> $content->getWorkflowId()

> $workflowId = $content->getWorkflowId()

> $storage = $c['storage']

> $workflow = $storage->getStorage('Workflow')->get($workflowId)

> echo $workflow->getArticleTitle()->getPrefixedText()
Talk:Content translation
>

Issue: eqiad cache contains obsolete data.

Fix

This time, I am intentionally not using the fixing script, as that makes updates in the database. Instead, I purge the cache only (from codfw):

Now running eval.php for mediawikiwiki inside pod/mw-debug.codfw.pinkunicorn-6b6d575bf7-8k29v on release pinkunicorn...
> $c = require "$IP/extensions/Flow/container.php";

> $wikipage = \MediaWiki\MediaWikiServices::getInstance()->getWikiPageFactory()->newFromTitle(Title::newFromText('Talk:Content_translation/Flow'))

> $content = $wikipage->getContent()

> $workflowId = $content->getWorkflowId()

> $storage = $c['storage']

> $workflowStorage = $storage->getStorage('Workflow')

> $workflow = $storage->getStorage('Workflow')->get($workflowId)

> $workflowStorage->cachePurge($workflow)

After the cache purge, eqiad returns the right value:

Now running eval.php for mediawikiwiki inside pod/mw-debug.eqiad.pinkunicorn-6996b8cd95-54dpk on release pinkunicorn...
> $c = require "$IP/extensions/Flow/container.php";

> $wikipage = \MediaWiki\MediaWikiServices::getInstance()->getWikiPageFactory()->newFromTitle(Title::newFromText('Talk:Content_translation/Flow'))

> $content = $wikipage->getContent()

> $workflowId = $content->getWorkflowId()

> $storage = $c['storage']

> $workflow = $storage->getStorage('Workflow')->get($workflowId)

> echo $workflow->getArticleTitle()->getPrefixedText()
Talk:Content translation/Flow
>

Should be fully resolved now.

Note: @Quiddity mentioned the move took a very long time (over 30 seconds). During that time, I was attempting to access the original location of the page (https://www.mediawiki.org/wiki/Talk:Content_translation) via eqiad. Considering the page got broken in eqiad only, "page being visited during a move" might be a factor that contributes to the issue.

Etonkovidova subscribed.

The page https://www.mediawiki.org/wiki/Talk:Content_translation is accessible now and all page revisions can be viewed.