WikiMO: Error: Call to a member function getPrefixedText() on a non-object on Special:ProtectedPages

VERIFIED FIXED

Status

VERIFIED FIXED
6 years ago
5 years ago

People

(Reporter: stephend, Assigned: jd)

Tracking

Details

(URL)

Attachments

(3 attachments)

(Reporter)

Description

6 years ago
https://wiki.mozilla.org/Special:ProtectedPages throws a 500:

Error: Call to a member function getPrefixedText() on a non-object

Sample stack trace

…at /data/www/wiki.mozilla.org/wiki/includes/specials/SpecialProtectedpages.php (135)
…at /data/www/wiki.mozilla.org/wiki/includes/specials/SpecialProtectedpages.php (320)
…sPager::formatRow called at /data/www/wiki.mozilla.org/wiki/includes/Pager.php (353)
…at /data/www/wiki.mozilla.org/wiki/includes/specials/SpecialProtectedpages.php (63)
…cute called at /data/www/wiki.mozilla.org/wiki/includes/SpecialPageFactory.php (476)
…ctory::executePath called at /data/www/wiki.mozilla.org/wiki/includes/Wiki.php (263)
…ki::performRequest called at /data/www/wiki.mozilla.org/wiki/includes/Wiki.php (593)
in MediaWiki::main called at /data/www/wiki.mozilla.org/wiki/includes/Wiki.php (503)
in MediaWiki::run called at /data/www/wiki.mozilla.org/wiki/index.php (58)
(Assignee)

Comment 1

6 years ago
that page loads for me, do you have any further details? like what skin you are using or if you are logged in or not etc...
(Reporter)

Comment 2

6 years ago
Created attachment 727882 [details]
Screenshot
(Reporter)

Comment 3

6 years ago
(In reply to Jason Crowe [:jd] from comment #1)
> that page loads for me, do you have any further details? like what skin you
> are using or if you are logged in or not etc...

Logged in, GMO theme set.
(Assignee)

Comment 4

6 years ago
While I cannot reproduce this on prod I am able to reproduce it consistently on dev I have some additional error logging enabled there but it sheds no light on the subject.

Hopefully hexmode has some ideas. If not then we will probably need to file a bug upstream to work towards a resolution.
I see the white page no matter what the skin I use.  Looking at the source.
Created attachment 727944 [details] [diff] [review]
patch for debugging

Could someone apply this patch, reproduce the error, and then tell me what the error log shows?
Also, it would be helpful to know if update.php was run after upgrading the wiki.  If it was, that would mean the db schema has been updated.
(Assignee)

Comment 8

6 years ago
Created attachment 728422 [details]
Debug Output

Hex,

I manually applied the patch to dev and hit the page, debug output attached.
So, for some reason there is a row in the list of protected pages in the MozillaWiki namespace without a title that is protected.  Since we can see the length of the page (1130), we can see the list before and after that page with the following links:

https://wiki.mozilla.org/Special:ProtectedPages?namespace=4&sizetype=max&size=1129
https://wiki.mozilla.org/Special:ProtectedPages?namespace=4&sizetype=min&size=1131

I'm not sure how this page would have gotten in there but maybe if we find the page, we can get a better idea of what happened.

Running the following query should produce the page:

 select page_id, page_title from  page, page_restrictions where page_id=pr_page and
 page_namespace=4 and page_len=1130
Maybe someone can run the cleanupTitles.php maintenance script on that wiki to
fix the broken rows?
Better fix: https://gerrit.wikimedia.org/r/#/c/56125/

If I knew were to apply that patch, I would.
(Assignee)

Comment 13

6 years ago
I ran the cleanupTitles.php maintenance script and the issue has gone away.

Hex, do I need to apply this patch or is it safe to wait till the next point release to just get it at that time?
Assignee: server-ops-webops → jcrowe
(Reporter)

Updated

6 years ago
Flags: needinfo?(mah)
you can wait on that.  cleanupTitles is enough.
Flags: needinfo?(mah)
(Assignee)

Comment 15

6 years ago
Thank you, I will close this out then.
Cheers
Status: NEW → RESOLVED
Last Resolved: 6 years ago
Resolution: --- → FIXED
(Reporter)

Comment 16

6 years ago
Looks good to me, thanks -- verified FIXED.
Status: RESOLVED → VERIFIED
Component: Server Operations: Web Operations → WebOps: Other
Product: mozilla.org → Infrastructure & Operations
You need to log in before you can comment on or make changes to this bug.