Topic on Manual talk:Skin autodiscovery

70.106.148.11 (talkcontribs)

I got annoyed with the error message, and it didn't go away after following the instructions in this article, so i went into /includes/debug/Debug.php, deleted the if function on line 303, and left my skin as-is. I plan to never upgrade, but security isn't an issue because I .htaccess protected the /wiki directory and chmod 600'd my .htaccess and LocalSettings.php.

88.130.104.217 (talkcontribs)

Modifying Core files is bad and should not be done.

The message in fact is generated in includes/Skin.php, function getSkinNames(). Basically there simply is a check for file names of PHP files, which are directly located inside the skins/ folder. Each of these files produces one such warning. Interestingly at least in 1.23, the Core itself still does use autodiscovery while it complains when you do in your skins. That is why there is this funny construct, which filters out Core skins before complaining. Because the Core is still using autodiscovery itself...

However, the solution is to update your skin accordingly. Afterwards the file directly in the folder skins/ is no longer needed and can be removed. With this removal, the warning will disappear.

95.109.55.58 (talkcontribs)

I've been trying to migrate my skin for a few hours without success.

Deleting this in Skin.php removed the error message:

if ( !in_array( $aSkin, array( 'CologneBlue', 'Modern', 'MonoBook', 'Vector' ) ) ) {
							wfLogWarning(
								"A skin using autodiscovery mechanism, $aSkin, was found in your skins/ directory. " .
								"The mechanism will be removed in MediaWiki 1.25 and the skin will no longer be recognized. " .
								"See https://www.mediawiki.org/wiki/Manual:Skin_autodiscovery for information how to fix this."
							);
						}

Thank you.

213.185.227.76 (talkcontribs)

Does this work and will it remove the errors so the wiki is usable again ? I'm lost in a state where nothing works right now but I was a bit uncertain about what code lines to change or remove not to make things even worse. Still if this is a working way forward I would try it as nothing else works right now anyway.

Kghbln (talkcontribs)

This error message is what I call spam. This does not give you time to migrate until 1.27 is out, it forces you to migrate immediately to avoid error logs reaching several megs a day.

88.130.118.177 (talkcontribs)

Several megabytes a day is what I call small. I had that after 5-10 minutes. Log rotation helps keep the file size usable and updating the custom skins helps prevent these notices from being created.

Kghbln (talkcontribs)

Admittedly I was pretty grumpy when writing my last post. No offence please. I ended up with 400 megs within a day after upgrading and I consider this one to be just a medium size wiki. I would like to have this message showing up on Special:Version or so rather than having this in the error log on every hit the wiki recieves.

Reply to "Error Message"