Last modified: 2014-11-06 17:29:51 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T75003, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 73003 - Flow: clicking Undo of a moderation action after you're logged out silently fails with fatal error
Flow: clicking Undo of a moderation action after you're logged out silently f...
Status: RESOLVED DUPLICATE of bug 73004
Product: MediaWiki extensions
Classification: Unclassified
Flow (Other open bugs)
master
All All
: Unprioritized normal (vote)
: ---
Assigned To: Matthias Mullie
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2014-11-05 05:21 UTC by spage
Modified: 2014-11-06 17:29 UTC (History)
5 users (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description spage 2014-11-05 05:21:10 UTC
While filing bug 72993 I let the "Scenario: Deleting a topic" delete the top-most topic with KEEP_BROWSER_OPEN=true.  I returned to this browser window an hour or more later and clicked the Undo button in the
 [This topic has been deleted. _Undo_]
flow-moderated-topic-title.

Nothing happened. I retried with the developer console Net tab open, and the POST request returned status 200 and 20 empty bytes.  According to cURL it's responding with 1f 8b 08 00 00 00 00 00 00 03 03 00 00 00 00 00 00 00 00 00

I think what happened is the Selenium user had been logged out due to session timeout (the QA tests do not check [ ] Keep me logged in when logging in), and then the attempt to report the failure blows up.  ee-flow's Apache log has *two* errors for the one request (below)
1. Undefined property: Flow\\Block\\TopicBlock::$user in  getDisallowedErrorMessage()
2. $this->user->isAllowed() call in getDisallowedErrorMessage() when there's no user in /srv/mediawiki/extensions/Flow/includes/Block/Topic.php 

both stemming from the user being logged out. I don't even see a $user member variable. Line 754 arose from mlitn's "Show more descriptive error message for insufficient permissions"

When an anonymous or logged-out user tries to view this deleted topic http://ee-flow.wmflabs.org/wiki/Topic:S5i6a0emy49f9668 , they see a blank HTML page  and the log has a similar error. I'll file that separately.

Here are the two errors logged when I repeated the undo POST request with curl, basically 'action=flow&format=json&submodule=moderate-topic&page=Topic%3AS5i6a0emy49f9668&mtreason=%3Cflow-topic-undo-delete%3E&mtmoderationState=undelete&token=%2B%5C'  Note the wrong-looking token.

All lines start with "[Wed Nov 05 04:41:39 2014] [error] [client 10.68.16.65] PHP" and end with ", referer: http://ee-flow.wmflabs.org/wiki/DUMMYCURL"

 Notice:  Undefined property: Flow\\Block\\TopicBlock::$user in /srv/mediawiki/extensions/Flow/includes/Block/Topic.php on line 754
 Stack trace:
   1. {main}() /srv/mediawiki/api.php:0
   2. ApiMain->execute() /srv/mediawiki/api.php:85
   3. ApiMain->executeActionWithErrorHandling() /srv/mediawiki/includes/api/ApiMain.php:362
   4. ApiMain->executeAction() /srv/mediawiki/includes/api/ApiMain.php:391
   5. ApiFlow->execute() /srv/mediawiki/includes/api/ApiMain.php:952
   6. ApiFlowBasePost->execute() /srv/mediawiki/extensions/Flow/includes/api/ApiFlow.php:81
   7. Flow\\WorkflowLoader->handleSubmit() /srv/mediawiki/extensions/Flow/includes/api/ApiFlowBasePost.php:19
   8. Flow\\SubmissionHandler->handleSubmit() /srv/mediawiki/extensions/Flow/includes/WorkflowLoader.php:63
   9. Flow\\Block\\AbstractBlock->onSubmit() /srv/mediawiki/extensions/Flow/includes/SubmissionHandler.php:104
  10. Flow\\Block\\TopicBlock->validate() /srv/mediawiki/extensions/Flow/includes/Block/Block.php:194
  11. Flow\\Block\\TopicBlock->loadTopicTitle() /srv/mediawiki/extensions/Flow/includes/Block/Topic.php:103
  12. Flow\\Block\\TopicBlock->getDisallowedErrorMessage() /srv/mediawiki/extensions/Flow/includes/Block/Topic.php:733

and immediately afterwards
 Fatal error:  Call to a member function isAllowed() on a non-object in /srv/mediawiki/extensions/Flow/includes/Block/Topic.php on line 754
 Stack trace:
   (identical)
Comment 1 spage 2014-11-05 07:29:31 UTC
I think this is an amalgamation of two other bugs:
 bug 73004 Flow: blank page/503 output viewing a deleted topic if you don't have rights
 bug 73007  Flow: API errors in Undo moderation aren't reported to the user

Firefox was acting weird, it's been a long night :)
Comment 2 Matthias Mullie 2014-11-06 17:29:51 UTC
Indeed, it's a combination of those 2 other bugs, so I'll close this one

*** This bug has been marked as a duplicate of bug 73004 ***

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links