Page MenuHomePhabricator

Flow: blank page viewing a deleted topic if you don't have rights
Closed, ResolvedPublic

Description

If you're anonymous or don't have delete rights, trying to view the topic deleted in bug 73003,
http://ee-flow.wmflabs.org/wiki/Topic:S5i6a0emy49f9668 ,
results in a blank HTML page.

The /var/log/apache2/error.log has much the same error lines: a problem with the call

if ( !$this->user->isAllowed( $logPage->getRestriction() ) )

in Block/Topic.php's getDisallowedErrorMessage()

[Wed Nov 05 05:16:02 2014] [error] [client 10.68.16.65] PHP Notice: Undefined property: Flow\\Block\\TopicBlock::$user in /srv/mediawiki/extensions/Flow/includes/Block/Topic.php on line 754

[Wed Nov 05 05:16:02 2014] [error] [client 10.68.16.65] PHP Fatal error: Call to a member function isAllowed() on a non-object in /srv/mediawiki/extensions/Flow/includes/Block/Topic.php on line 754

this occurs even if I'm logged in as a regular user without delete rights. I just don't think there's a user member variable. Should've written a test for this function :-|

Visiting a deleted topic on beta labs like http://en.wikipedia.beta.wmflabs.org/wiki/Topic:S5hlsouqvx6pndn6 gives a 503 error, probably due to the interaction with HHVM.


Version: master
Severity: normal

Details

Reference
bz73004

Event Timeline

bzimport raised the priority of this task from to Needs Triage.Nov 22 2014, 3:48 AM
bzimport set Reference to bz73004.

gerritadmin wrote:

Change 171310 had a related patch set uploaded by Matthias Mullie:
blank page/503 output viewing a deleted topic if you don't have rights

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

  • Bug 73003 has been marked as a duplicate of this bug. ***

gerritadmin wrote:

Change 171310 merged by jenkins-bot:
blank page/503 output viewing a deleted topic if you don't have rights

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

Now I see a skinned wiki page, but the content area is empty.
E.g. visit http://en.wikipedia.beta.wmflabs.org/wiki/Topic:S5onnqdlmu3w5236 as an anon or a user without delete rights.

The page <title> tag is not bad, "This topic was deleted by Selenium user on Talk:Flow QA".

In bug 60155#c3 Jon said "I can see the heading error and it tells me I don't have permission." so something changed recently.

ErikB comments:
I suppose it should resemble visiting a revdel'd page revision, an i18n message like 'deletedtext' in a centered white box, like

"This page revision has been deleted. Details can be found in the 
       deletion log."