Last modified: 2014-11-07 20:19:29 UTC
The following error occurred on ee-flow, which is running b67dc7a. --- An error has occurred. Return to Main Page. [b8e22f9c] /wiki/User_talk:Spage Exception from line 112 of /srv/mediawiki/extensions/Flow/includes/Model/Workflow.php: Could not create UserTuple for workflow_user_ Backtrace: #0 [internal function]: Flow\Model\Workflow::fromStorageRow(array, NULL) #1 /srv/mediawiki/extensions/Flow/includes/Data/Mapper/CachingObjectMapper.php(84): call_user_func(array, array, NULL) #2 /srv/mediawiki/extensions/Flow/includes/Data/ObjectLocator.php(306): Flow\Data\Mapper\CachingObjectMapper->fromStorageRow(array) #3 /srv/mediawiki/extensions/Flow/includes/Data/ObjectManager.php(127): Flow\Data\ObjectLocator->load(array) #4 /srv/mediawiki/extensions/Flow/includes/Data/ObjectLocator.php(93): Flow\Data\ObjectManager->load(array) #5 /srv/mediawiki/extensions/Flow/includes/Data/ObjectLocator.php(48): Flow\Data\ObjectLocator->findMulti(array, array) #6 /srv/mediawiki/extensions/Flow/includes/WorkflowLoaderFactory.php(98): Flow\Data\ObjectLocator->find(array) #7 /srv/mediawiki/extensions/Flow/includes/WorkflowLoaderFactory.php(74): Flow\WorkflowLoaderFactory->loadWorkflow(Title) #8 /srv/mediawiki/extensions/Flow/includes/Actions/Action.php(75): Flow\WorkflowLoaderFactory->createWorkflowLoader(Title, NULL) #9 /srv/mediawiki/extensions/Flow/includes/Actions/Action.php(33): Flow\Actions\FlowAction->showForAction(string) #10 /srv/mediawiki/includes/MediaWiki.php(414): Flow\Actions\FlowAction->show() #11 /srv/mediawiki/includes/MediaWiki.php(282): MediaWiki->performAction(Article, Title) #12 /srv/mediawiki/includes/MediaWiki.php(584): MediaWiki->performRequest() #13 /srv/mediawiki/includes/MediaWiki.php(435): MediaWiki->main() #14 /srv/mediawiki/index.php(46): MediaWiki->run() #15 {main}
There is illegal state in the database: select * from testwiki.flow_workflow where workflow_user_id = 0 and workflow_user_ip = ''; 3 matching rows, including the one that causes this error. Either user_id can be 0 or user_ip can be unset, but one has to be a valid value. Somehow this is/was not being enforced somewhere.
Erik suggested having UserTuple enforce a valid state. I think this can be done in the constructor. That will then hopefully reveal what is creating bogus UserTuples (since it will throw before it makes it to the database). This may require changing IRCLineUrlFormatter to not construct mock workflows (the UserTuple logic can't be air-tight if there is an exception for this (as there currently is). We also need to figure out what to do with the already-corrupt data on the test wiki. Simplest solution is probably to assign it to someone manually.
in backlog: https://trello.com/c/lle97F1m
I think the same Could not create UserTuple' exception silently aborts the display of my recent http://ee-flow.wmflabs.org/wiki/Special:Contributions/Spage without any indication there's been a failure. Can failure to load provide a dummy object so at least the rest of the page is visible?
Change 171466 had a related patch set uploaded by EBernhardson: Bug: prod db contains rows with both *_user_id and *_user_ip set https://gerrit.wikimedia.org/r/171466
*** Bug 73153 has been marked as a duplicate of this bug. ***