FANDOM


This is the talk page for discussing improvements to the Repository page.

Error enabling ArticleComments extension

Hi,

It's the very first time that I try to enable any MediaWiki extension made by wikia in a private setup and I, as expected, got an error.

As a result of php maintenance/update.php I got

PHP Fatal error: Class 'F' not found in /opt/bitnami/apps/mediawiki/htdocs/extensions/wikia/ArticleComments/ArticleComments_setup.php on line 96

I'm running a clean setup of MediaWiki 1.19.1 on a bitnami virtual machine.

Maybe the error is related to the custom core changes on MediaWiki made by wikia?

Best, 555 04:02, July 1, 2012 (UTC)

Hi, Wikia has its own custom MW framework, Nirvana, as well as several other changes. Try downloading the contents of https://github.com/Wikia/app/tree/dev/includes/wikia into a folder named wikia in your installation's includes folder. TK-999 (talk) 20:17, October 1, 2013 (UTC)

Installing public Wikia code

Hi,

I want to install Wikia. Redirected to the setup on: http://localhost/wikia/mw-config/index.php ...I get the following output: Error, Setup.php must be included from the file scope, after DefaultSettings.php Is there any help availabel to solve this problem? Samual3 (talk) 20:02, October 1, 2013 (UTC)

Place require_once "$IP/includes/DefaultSettings.php"; somewhere before line 174 in includes/WebStart.php. TK-999 (talk) 20:17, October 1, 2013 (UTC)
Same issue here adding that line do not help. All I get now is a blank white page. Adrianevs (talk) 21:43, October 6, 2017 (UTC)
The discussion you're replying to is over 4 years old and very outdated. If you want to set up a local Wikia instance, try asking Staff about it over Special:Contact/general. -- Cube-shaped garbage can 21:49, October 6, 2017 (UTC)

Example LocalSettings.php

Hello,


is there any example of the LocalSettings.php of Wikia and its extension available? Samual3 (talk) 20:11, October 1, 2013 (UTC)

Not that I'm aware of TK-999 (talk) 20:17, October 1, 2013 (UTC)
Let's say we want to install a specific extension form the Wikia repo. Is there a way to determine the necessary wg-variables and could we be sure that database changes for the extension will be handled over "/maintenance/update.php"?  Samual3 (talk) 21:59, October 1, 2013 (UTC)
I believe most Wikia extensions are self-contained (except for Wikia-specific includes as outlined above), so theoretically stuff should work. TK-999 (talk) 20:41, October 1, 2013 (UTC)
Thank you for reply. Samual3 (talk) 03:36, October 2, 2013 (UTC)

Some Contributions

Currently the code from the public Wikia repo is not installable. This makes it inmpossible for external developers to contribute to the project, or participate in development of outstanding Wiki-extensions. I could locate the following bugs, invalid PHP codings, hard coded references and notices:

PHP Parse error: syntax error, unexpected '[' in C:\\xampp\\htdocs\\ImproveWikia\\includes\\wikia\\DefaultSettings.php on line 1109, 
referer: http://localhost/ImproveWikia/

$wgPhalanxServiceOptions = [];<--!


PHP Parse error: syntax error, unexpected '[' in  C:\\xampp\\htdocs\\ImproveWikia\\includes\\Title.php on line 2015, 
referer: http://localhost/ImproveWikia/

$groups = ['staff','vstf',];<--!

PHP Warning:  include_once(/usr/wikia/deploy/code/src/wgCacheBuster.php) [<a href='function.include-once'>function.include-once</a>]: 
failed to open stream: No such file or directory in C:\\xampp\\htdocs\\ImproveWikia\\includes\\wikia\\wgCacheBuster.php on line 16, 
referer: http://localhost/ImproveWikia/

PHP Warning:  include_once() [<a href='function.include'>function.include</a>]: 
Failed opening '/usr/wikia/deploy/code/src/wgCacheBuster.php' for inclusion (include_path='.;C:\\xampp\\php\\PEAR') 
in C:\\xampp\\htdocs\\ImproveWikia\\includes\\wikia\\wgCacheBuster.php on line 16, referer: http://localhost/ImproveWikia/


PHP Notice:  Undefined variable: wgEnableSelenium in C:\\xampp\\htdocs\\wikia\\includes\\WebStart.php on line 144, 
referer: http://localhost/wikia/

PHP Notice:  Undefined variable: wgCacheBuster in C:\\xampp\\htdocs\\wikia\\includes\\wikia\\DefaultSettings.php on line 24, 
referer: http://localhost/wikia/ 

...Alfter fixing/hinting the above, $wgShowExceptionDetails = true; outputs: 

Mediawiki tried to access the database via wfGetDB(). This is not allowed.

C:\xampp\htdocs\ImproveWikia\includes\GlobalFunctions.php(3549): LBFactory_Fake->getMainLB(false)#1 
C:\xampp\htdocs\ImproveWikia\includes\GlobalFunctions.php(3539): wfGetLB(false)#2 
C:\xampp\htdocs\ImproveWikia\includes\objectcache\SqlBagOStuff.php(80): wfGetDB(-2)#3 
C:\xampp\htdocs\ImproveWikia\includes\objectcache\SqlBagOStuff.php(121): SqlBagOStuff->getDB()#4 
C:\xampp\htdocs\ImproveWikia\includes\cache\MessageCache.php(313): SqlBagOStuff->get('my_wiki:message...')#5 
C:\xampp\htdocs\ImproveWikia\includes\cache\MessageCache.php(723): MessageCache->load('en')#6 
C:\xampp\htdocs\ImproveWikia\includes\cache\MessageCache.php(645): MessageCache->getMsgFromNamespace('Config-page-lan...', 'en')#7 
C:\xampp\htdocs\ImproveWikia\includes\GlobalFunctions.php(1455): MessageCache->get('config-page-lan...', true, false)#8 
C:\xampp\htdocs\ImproveWikia\includes\GlobalFunctions.php(1431): wfMsgGetKey('config-page-lan...', true, false, true)#9 
C:\xampp\htdocs\ImproveWikia\includes\GlobalFunctions.php(1335): wfMsgReal('config-page-lan...', Array)#10 
C:\xampp\htdocs\ImproveWikia\includes\installer\WebInstaller.php(543): wfMsg('config-page-lan...')#11 
C:\xampp\htdocs\ImproveWikia\includes\installer\WebInstaller.php(516): WebInstaller->getPageListItem('Language', true, 'Language')#12 
C:\xampp\htdocs\ImproveWikia\includes\installer\WebInstaller.php(248): WebInstaller->startPageWrapper('Language')#13 
C:\xampp\htdocs\ImproveWikia\mw-config\index.php(50): WebInstaller->execute(Array)#14 
C:\xampp\htdocs\ImproveWikia\mw-config\index.php(18): wfInstallerMain()#15 {main} 


...all done before second MediaWiki setup screen.

Are there any suggestions available to solve this problems?

I use Linux as well as Windows. Samual3 (talk) 23:20, October 1, 2013 (UTC)

"Not installable" is unlikely to be completely correct. You can try asking Grunny here on dev, or email staff through Special:contact/general. I don't see why staff would be unwilling to give you a default Wikia LocalSettings.php file example (you can try creating a new wiki and asking for that wiki's which I assume would be default). Alternatively, there might be something in the CreateWiki extension on Wikia's github repo that describes the default settings.
But I will agree it is extremely hard for any outsider to contribute or build upon Wikia's codebase. The only example I've ever come across is mw:Extension:Phalanx. Wikia's code is getting increasingly integrated into their setup and whilst there are certain areas that they have moved back to core (such as the wikimedia visualeditor) there aren't many cases. cqm 09:22, 2 Oct 2013 (UTC)

Hello Cpm thank you for your advice I surely will give it a try.

I successfully installed Visual Editor (beta) on a MW-test installation and contributed to the Parsoid project a while ago. Then I recognized that the Wikia-version of VE is mutch more feature rich. That's the main reason I came here. I would believe VE for MW and VE for Wikia are currently two different things and hope both can have the same feature richness once VE is declared as stable.

What I currently don't understand is how internal Wikia-devolopers can remotely merge on GitHub, while the above mentioned bugs exists in the app, app-dev and app-dev-test- branches. Normally they would have a local buggy system, or they know how to avoid it with "special" non public configuration steps. In other GitHub-hosted projects are usually latest stable branches announced. I will ask the developers first. Thank you again. Samual3

Your PHP version is too old, it should be at least PHP 5.4.x., based on the fact your installed PHP does not recognize the array literal syntax. TK-999 (talk) 15:47, October 3, 2013 (UTC)

Ah OK, thank you TK-999. That was one of my first assumptions- but I didn't followed it initialy and used the old syntax. Can you say something to the Error: "Mediawiki tried to access the database via wfGetDB(). This is not allowed." It seems it comes from the load balancer configurations (LBFactory). I do not need any load balancer for developments. How can I deactivate this code while installation or in general? Or is there an automatic fall back if I change the PHP-engine?

--Samual3 (talk) 17:08, October 3, 2013 (UTC)

Go through the steps in https://www.mediawiki.org/wiki/XAMPP , then try again. TK-999 (talk) 17:17, October 3, 2013 (UTC)

I've updated the XAMPP-environment accordingly (PHP 5.4). The error doesn't disapear:

Mediawiki tried to access the database via wfGetDB(). This is not allowed. (second MediaWiki setup screen)

As I said LBFactory causes this output. Can I deactivate it somewhere in DefaultSettings.php?

PS: I temporary commented out the hard coded include statement for "wgCacheBuster.php":

Notice: Undefined variable: wgEnableSelenium in C:\xampp\htdocs\wikia\includes\WebStart.php on line 144

Warning: include_once(/usr/wikia/deploy/code/src/wgCacheBuster.php): failed to open stream: No such file or directory in C:\xampp\htdocs\wikia\includes\wikia\wgCacheBuster.php on line 16

Warning: include_once(): Failed opening '/usr/wikia/deploy/code/src/wgCacheBuster.php' for inclusion (include_path='.;\xampp\php\PEAR') in C:\xampp\htdocs\wikia\includes\wikia\wgCacheBuster.php on line 16

Notice: Undefined variable: wgCacheBuster in C:\xampp\htdocs\wikia\includes\wikia\DefaultSettings.php on line 24

Any solotions?

--Samual3 (talk) 18:58, October 3, 2013 (UTC)

Did you create & configure a database for MediaWiki as outlined on https://www.mediawiki.org/wiki/XAMPP ? TK-999 (talk) 20:00, October 3, 2013 (UTC)

The error occurs before any DB-Configurations just behind the click on MediaWikis "Please set up the wiki first - link". Even If I setup blindly a MySQL-DB. I see you forking "app" on GitHub. How do you manage this? Do you have a local load balancer on board? Do I have to create any Wikia-related DB like "$wgExternalDatawareDB" before MediaWiki install? Or is there a separate install for the Wikia branch?

--Samual3 (talk) 20:14, October 3, 2013 (UTC)

Try setting $wgDevelEnvironment to true in LocalSettings.php before wgCacheBuster.php is included—that should fix the inclusion issue. TK-999 (talk) 21:32, October 3, 2013 (UTC)

OK, "include- issue" is fixed, but I still get the "wfGetDB()-Error" just before any DB-configuration question in the Setup GUI of MediaWiki. How can I solve this problem? --Samual3 (talk) 21:53, October 3, 2013 (UTC)

Did you properly configure SQL access in LocalSettings.php? See https://www.mediawiki.org/wiki/Manual:Database_access#Logging_into_MySQL how. TK-999 (talk) 22:08, October 3, 2013 (UTC)

I have no LocalSettings.php as yet- because MediaWiki writes this file while setup- which currently breaks because of the mentioned error. --Samual3 (talk) 22:13, October 3, 2013 (UTC) ;-)

Any suggestions?

I asked about getting a default LocalSettings.php with one of the community support staff: it's a massive no no. Apparently it contains lots of passwords to their servers which obviously aren't going to be publicised to anyone who isn't staff. It's too much of a security risk. cqm 20:41, 11 Oct 2013 (UTC)

I also asked the Wikia support for a default LocalSettings.php without any confidential data. The response from tech. support was: "It is to much efford". They also said that the following Wikia developer page contains old and miss-leading content: http://dev.wikia.com/wiki/Wikia_Developers_Wiki for example:

Get Started We'll help developers help the community! We can get interested developers set up with test facilities, so you can write a feature and have everyone see it soon.

They said they will try to modify the article accordingly.

I' m very disappointed about this situation- since I invested many days on this issue, following obviously and officially confirmed miss-leading informations.

--Samual3 (talk) 01:31, October 14, 2013 (UTC)

Any update regard installing public Wikia code on local server?

Any update regard installing public Wikia code on local server?  is there a page explain how?

I got:

Fatal error: Uncaught RuntimeException: Datacenter not configured in WIKIA_DATACENTER env variable. in F:
\LocalServer\htdocs\wikia\LocalSettings.php:34 Stack trace: #0 F:\LocalServer\htdocs\wikia\includes\WebStart.php
(137): require_once() #1 F:\LocalServer\htdocs\wikia\index.php(58): require('F:\\LocalServer\\...') #2 {main} thrown
in F:\LocalServer\htdocs\wikia\LocalSettings.php on line 34 


DeuzExMachina (talk) 23:51, September 13, 2019 (UTC)

Community content is available under CC-BY-SA unless otherwise noted.

Fandom may earn an affiliate commission on sales made from links on this page.

Stream the best stories.

Fandom may earn an affiliate commission on sales made from links on this page.

Get Disney+