Wikidata has been deployed on production for quite a while now but beta still does not have a Wikidata wiki. We need to create a new one, possibly under the name wikidata.beta.wmflabs.org .
Version: unspecified
Severity: enhancement
Wikidata has been deployed on production for quite a while now but beta still does not have a Wikidata wiki. We need to create a new one, possibly under the name wikidata.beta.wmflabs.org .
Version: unspecified
Severity: enhancement
Related URL: https://gerrit.wikimedia.org/r/61428 (Gerrit Change I7ae71e3b1a2a3115c4e704134b0e3c4130d71876)
I got a basic setup at http://wikidata.beta.wmflabs.org/
That emits a stack trace though:
failed to deserialize
Backtrace:
#0 /data/project/apache/common-local/php-master/extensions/Wikibase/lib/includes/EntityFactory.php(141): Wikibase\EntityFactory->unserializedData('==This subdomai...', 'application/jso...')
#1 /data/project/apache/common-local/php-master/extensions/Wikibase/repo/includes/content/ItemHandler.php(69): Wikibase\EntityFactory->newFromBlob('item', '==This subdomai...', 'application/jso...')
#2 /data/project/apache/common-local/php-master/includes/Revision.php(1010): Wikibase\ItemHandler->unserializeContent('==This subdomai...', 'application/jso...')
#3 /data/project/apache/common-local/php-master/includes/Revision.php(951): Revision->getContentInternal()
#4 /data/project/apache/common-local/php-master/includes/WikiPage.php(634): Revision->getContent(1, NULL)
#5 /data/project/apache/common-local/php-master/includes/WikiPage.php(464): WikiPage->getContent()
#6 [internal function]: WikiPage->isRedirect()
#7 /data/project/apache/common-local/php-master/includes/Article.php(1961): call_user_func_array(Array, Array)
#8 /data/project/apache/common-local/php-master/includes/Wiki.php(374): Article->__call('isRedirect', Array)
#9 /data/project/apache/common-local/php-master/includes/Wiki.php(374): Article->isRedirect()
#10 /data/project/apache/common-local/php-master/includes/Wiki.php(295): MediaWiki->initializeArticle()
#11 /data/project/apache/common-local/php-master/includes/Wiki.php(565): MediaWiki->performRequest()
#12 /data/project/apache/common-local/php-master/includes/Wiki.php(458): MediaWiki->main()
#13 /data/project/apache/common-local/php-master/index.php(55): MediaWiki->run()
#14 /data/project/apache/common-local/w/index.php(3): require('/data/project/a...')
#15 {main}
I have disabled the WikibaseRepo extension on beta wikidata ( https://gerrit.wikimedia.org/r/65838 ). That at least let us show the main page now.
I have imported the production Wikidata:Main_page as well as MediaWiki:common.css then changed the wiki main page to be Wikidata:Main_page. Enabled WikibaseRepo again https://gerrit.wikimedia.org/r/65839
The main page no more produce a stack trace.
http://wikidata.beta.wmflabs.org/wiki/Wikidata:Main_Page
I have ZERO idea how to create new items to test out whether it works properly.
you did the right thing :) The default main page is wikitext and we set the main namespace to be entity content.
The entity content handler chokes on wikitext content. The other thing to do would be temporarily disable wikibase and delete the page. Then re-enable Wikibase.
We will need to have the populateSitesTable maintenance script run via puppet, in order to add items.
On beta I ran:
$ mwscript extensions/Wikibase/lib/maintenance/populateSitesTable.php --wiki=wikidatawiki
done.
$
The maintenance script is hardcoded for production:
$wiki = $this->getOption( 'load-from', 'https://meta.wikimedia.org/w/api.php' );
Need to pass a different --load-from :D
The api URL should be http://deployment.wikimedia.beta.wmflabs.org/w/api.php . Due to labs instance running behind a NAT, they can not access the FQDN (bug 45868). On deployment-bastion I have setup a hack to rewrite the IP packet to points directly to the instance cache:
root@deployment-bastion:~# iptables -t nat -I OUTPUT --dest 208.80.153.219 -j DNAT --to-dest 10.4.0.17
Then reran the command with the proper URL:
$ mwscript extensions/Wikibase/lib/maintenance/populateSitesTable.php --wiki=wikidatawiki --load-from=http://deployment.wikimedia.beta.wmflabs.org/w/api.php
done.
$
Following a discussion with Aude on IRC, I truncated the wikidatawiki tables sites and sites_identifiers which were containing production information then reran the populateSitesTable.php script.
Result:
(mw@deployment-sql02) [wikidatawiki]> select * from site_identifiers;
+---------+------------+---------------+
si_site | si_type | si_key |
+---------+------------+---------------+
1 | equivalent | aa |
1 | interwiki | aa |
2 | equivalent | de |
2 | interwiki | de |
3 | equivalent | dewikivoyage |
3 | interwiki | dewikivoyage |
4 | equivalent | en |
4 | interwiki | en |
5 | equivalent | enwiktionary |
5 | interwiki | enwiktionary |
6 | equivalent | enwikibooks |
6 | interwiki | enwikibooks |
7 | equivalent | enwikinews |
7 | interwiki | enwikinews |
8 | equivalent | enwikiquote |
8 | interwiki | enwikiquote |
9 | equivalent | enwikisource |
9 | interwiki | enwikisource |
10 | equivalent | enwikiversity |
10 | interwiki | enwikiversity |
11 | equivalent | enwikivoyage |
11 | interwiki | enwikivoyage |
12 | equivalent | eo |
12 | interwiki | eo |
13 | equivalent | he |
13 | interwiki | he |
14 | equivalent | simple |
14 | interwiki | simple |
15 | equivalent | sq |
15 | interwiki | sq |
+---------+------------+---------------+
30 rows in set (0.00 sec)
(mw@deployment-sql02) [wikidatawiki]> select site_global_key, REVERSE(site_domain) from sites;
+-----------------+------------------------------------+
site_global_key | REVERSE(site_domain) |
+-----------------+------------------------------------+
aawiki | .aa.wikipedia.beta.wmflabs.org |
dewiki | .de.wikipedia.beta.wmflabs.org |
dewikivoyage | .de.wikivoyage.beta.wmflabs.org |
enwiki | .en.wikipedia.beta.wmflabs.org |
enwiktionary | .en.wiktionary.beta.wmflabs.org |
enwikibooks | .en.wikibooks.beta.wmflabs.org |
enwikinews | .en.wikinews.beta.wmflabs.org |
enwikiquote | .en.wikiquote.beta.wmflabs.org |
enwikisource | .en.wikisource.beta.wmflabs.org |
enwikiversity | .en.wikiversity.beta.wmflabs.org |
enwikivoyage | .en.wikivoyage.beta.wmflabs.org |
eowiki | .eo.wikipedia.beta.wmflabs.org |
hewiki | .he.wikipedia.beta.wmflabs.org |
simplewiki | .simple.wikipedia.beta.wmflabs.org |
sqwiki | .sq.wikipedia.beta.wmflabs.org |
+-----------------+------------------------------------+
15 rows in set (0.00 sec)
(mw@deployment-sql02) [wikidatawiki]>
So I guess it is running fine now.