Topic on Project:Support desk

Star Warden (talkcontribs)

Hi. When trying to access this page on the wiki (http://dragon-mania-legends-wiki.mobga.me/Trainer%27s_Pet_Event_(15/09/25)), I get this error: Fatal error: Call to a member function getLocalURL() on a non-object in /srv/dml-wiki/includes/skins/Skin.php on line 1051

I went to that line in that php and I found this: return $title->getLocalURL( $urlaction );

So far, it seems it's the only page acting up. Could anyone give me a solution, please?

87.123.33.228 (talkcontribs)

You are using MediaWiki 1.27. I have tested this in your wiki and this is happening with Vector, but also with Monobook, but only on that one page. Other pages display correctly.

Your problem is that for some reason, $title is not a title object at that point. From reading the code I think that this part of the code only is used to create a link to a special page.

In your case, SpecialPage::getSafeTitleFor( $name ); does not return a title object.

A complete backtrace would be great.
Star Warden (talkcontribs)

All right. And how do I give a complete backtrace?

Ciencia Al Poder (talkcontribs)
Star Warden (talkcontribs)

Hey. We found the error without having to backtrace. It's the apostrophe in the title that was causing the issue. As you can see, all events that have the apostrophe return the same error:
http://dragon-mania-legends-wiki.mobga.me/Freedom%27s_Reward_Event_(16/07/04)
http://dragon-mania-legends-wiki.mobga.me/Ladies%27_Choice_Event_(15/03/06)
http://dragon-mania-legends-wiki.mobga.me/Veteran%27s_Victory_Event_(15/11/09)
etc.

Aside from effectively removing it from the title, is there any other better sign with which we could replace it and not resort to sticking the possessive to the word?

87.123.36.209 (talkcontribs)

Although not recommended to be used, apostrophes are allowed in URLs and MediaWiki also can cope with them, e.g. en:Lady's Magazine.

An idea might be to check, why this is not working on your server and to fix the reason - or to use different page titles without apostrophe.

Star Warden (talkcontribs)

To be completely honest, I am not a programmer, I just try to follow the instructions given. With that in mind, how do I find why it's not working? And I've tried using other signs, like the prime or a different-looking comma, but both give the same error....

Ciencia Al Poder (talkcontribs)

Getting a backtrace would be helpful to see what's calling that method, possibly passing an invalid parameter. If that's hard, try disabling all extension and see if the problem still happens.

Star Warden (talkcontribs)

Hey. I didn't backtrace, but I disabled extensions, as you suggested me to, and I found that Extension:Contributors is the culprit. Why though?

Ciencia Al Poder (talkcontribs)

Extension talk:Contributors has other people complaining about that, but I don't see a bug about that on phabricator... Looks like nobody cares enough to report it so devs are aware of the bug.

Star Warden (talkcontribs)

I can open up a bug report, but I am not exactly sure how to formulate it to be as precise as possible. I mean, I could give the error that I am getting, but that points to folders on my wiki's server, so it would be different from what others reported.

AKlapper (WMF) (talkcontribs)
Star Warden (talkcontribs)

Yes, I am aware of HOW to report it, but I am not sure how to formulate the error itself so as to be as precise as possible.

Ciencia Al Poder (talkcontribs)

Just try it. If devs need further information they'll ask in the task.

Star Warden (talkcontribs)
Stefahn (talkcontribs)

Ran into the same (unsolved) issue and added a comment to the bug report.

Bawolff (talkcontribs)

There should be a fix in master now. Try redownloading the extension (Make sure to select the master branch of the extension)