Last modified: 2014-01-14 17:29:08 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 T61614, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 59614 - Enabling LocalisationUpdate extension in initial MediaWiki setup raises exception
Enabling LocalisationUpdate extension in initial MediaWiki setup raises excep...
Status: RESOLVED DUPLICATE of bug 46885
Product: MediaWiki extensions
Classification: Unclassified
LocalisationUpdate (Other open bugs)
unspecified
All Windows 7
: Unprioritized major (vote)
: ---
Assigned To: Nobody - You can work on this!
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2014-01-03 21:54 UTC by Iaroslav Vassiliev
Modified: 2014-01-14 17:29 UTC (History)
3 users (show)

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


Attachments

Description Iaroslav Vassiliev 2014-01-03 21:54:59 UTC
Enabling this extension in initial MediaWiki setup (1.22.0 on Windows) raises the following exception when trying to access main page for the first time:

[9215b846] /w22/index.php Exception from line 549 of C:\xampp\htdocs\w22\extensions\LocalisationUpdate\LocalisationUpdate.class.php: No cache directory configured

Backtrace:

#0 C:\xampp\htdocs\w22\extensions\LocalisationUpdate\LocalisationUpdate.class.php(561): LocalisationUpdate::filename(string)
#1 C:\xampp\htdocs\w22\extensions\LocalisationUpdate\LocalisationUpdate.class.php(36): LocalisationUpdate::readFile(string)
#2 [internal function]: LocalisationUpdate::onRecache(LocalisationCache, string, array)
#3 C:\xampp\htdocs\w22\includes\Hooks.php(199): call_user_func_array(string, array)
#4 C:\xampp\htdocs\w22\includes\GlobalFunctions.php(3877): Hooks::run(string, array)
#5 C:\xampp\htdocs\w22\includes\cache\LocalisationCache.php(853): wfRunHooks(string, array)
#6 C:\xampp\htdocs\w22\includes\cache\LocalisationCache.php(442): LocalisationCache->recache(string)
#7 C:\xampp\htdocs\w22\includes\cache\LocalisationCache.php(365): LocalisationCache->initLanguage(string)
#8 C:\xampp\htdocs\w22\includes\cache\LocalisationCache.php(281): LocalisationCache->loadSubitem(string, string, string)
#9 C:\xampp\htdocs\w22\languages\Language.php(2337): LocalisationCache->getSubitem(string, string, string)
#10 C:\xampp\htdocs\w22\includes\cache\MessageCache.php(802): Language->getMessage(string)
#11 C:\xampp\htdocs\w22\includes\cache\MessageCache.php(729): MessageCache->getMessageFromFallbackChain(LanguageRu, string, string, boolean)
#12 C:\xampp\htdocs\w22\includes\Message.php(878): MessageCache->get(string, boolean, LanguageRu)
#13 C:\xampp\htdocs\w22\includes\Message.php(560): Message->fetchMessage()
#14 C:\xampp\htdocs\w22\includes\Message.php(649): Message->toString()
#15 C:\xampp\htdocs\w22\includes\Title.php(375): Message->text()
#16 C:\xampp\htdocs\w22\includes\Wiki.php(121): Title::newMainPage()
#17 C:\xampp\htdocs\w22\includes\Wiki.php(137): MediaWiki->parseTitle()
#18 C:\xampp\htdocs\w22\includes\Wiki.php(530): MediaWiki->getTitle()
#19 C:\xampp\htdocs\w22\includes\Wiki.php(467): MediaWiki->main()
#20 C:\xampp\htdocs\w22\index.php(49): MediaWiki->run()
#21 {main}


Setting $wgCacheDirectory manually resolves the situation.
Comment 1 Andre Klapper 2014-01-05 03:15:15 UTC
Thanks for reporting this.

(In reply to comment #0)
> Enabling this extension in initial MediaWiki setup (1.22.0 on Windows)

I assume you also use the REL1_22 branch of the extension? Or git master?

> Setting $wgCacheDirectory manually resolves the situation.

Does that mean that $wgCacheDirectory was not set (empty) before?
Comment 2 Iaroslav Vassiliev 2014-01-06 11:41:35 UTC
I used extension version bundled with MediaWiki 1.22.0 public download package.

$wgCacheDirectory was empty. There was no messages about undefined variables, so it was defined, but empty. As you can see, this exception is thrown when both $wgLocalisationUpdateDirectory and $wgCacheDirectory are empty.

line 549 of LocalisationUpdate.class.php:

  $dir = $wgLocalisationUpdateDirectory ?
	$wgLocalisationUpdateDirectory :
	$wgCacheDirectory;

  if ( !$dir ) {
	throw new MWException( 'No cache directory configured' );
  }
Comment 3 bennylin 2014-01-14 17:09:49 UTC
I had this error to and I found the solution:

I'm using MW 1.22.1 that I downloaded today, and got the same error. 

According to it's extension page ([[mediawiki:Extension:LocalisationUpdate]]), you only need to add the following code in the LocalSettings.php

$wgLocalisationUpdateDirectory = "$IP/cache";
Comment 4 bennylin 2014-01-14 17:14:10 UTC
Second try: [[mw:Extension:LocalisationUpdate]]
Comment 5 bennylin 2014-01-14 17:29:08 UTC

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

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


Navigation
Links