Last modified: 2014-11-12 18:09:10 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 T44913, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 42913 - Better error message if default MW main page already exists
Better error message if default MW main page already exists
Status: NEW
Product: MediaWiki extensions
Classification: Unclassified
WikidataRepo (Other open bugs)
unspecified
All All
: Normal minor (vote)
: ---
Assigned To: Wikidata bugs
: easy, i18n, need-volunteer
Depends on:
Blocks: messages
  Show dependency treegraph
 
Reported: 2012-12-10 13:11 UTC by Silke Meyer (WMDE)
Modified: 2014-11-12 18:09 UTC (History)
6 users (show)

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


Attachments

Description Silke Meyer (WMDE) 2012-12-10 13:11:03 UTC
When the web-based installer is used, a default main page is created. When later this becomes a Wikibase repo, this main page "thinks" it is an item.
The error message should make the user notice this. Instead, it says something hard to debug...

failed to deserialize

Backtrace:

#0 /srv/testrepo/w/extensions/Wikibase/lib/includes/entity/EntityFactory.php(139): Wikibase\EntityFactory->unserializedData(''''MediaWiki ha...', 'application/jso...')
#1 /srv/testrepo/w/extensions/Wikibase/repo/includes/content/ItemHandler.php(86): Wikibase\EntityFactory->newFromBlob('item', ''''MediaWiki ha...', 'application/jso...')
#2 /srv/testrepo/w/includes/Revision.php(1005): Wikibase\ItemHandler->unserializeContent(''''MediaWiki ha...', 'application/jso...')
#3 /srv/testrepo/w/includes/Revision.php(946): Revision->getContentInternal()
#4 /srv/testrepo/w/includes/WikiPage.php(616): Revision->getContent(1)
#5 /srv/testrepo/w/includes/WikiPage.php(448): WikiPage->getContent()
#6 [internal function]: WikiPage->isRedirect()
#7 /srv/testrepo/w/includes/Article.php(1944): call_user_func_array(Array, Array)
#8 /srv/testrepo/w/includes/Wiki.php(364): Article->__call('isRedirect', Array)
#9 /srv/testrepo/w/includes/Wiki.php(364): Article->isRedirect()
#10 /srv/testrepo/w/includes/Wiki.php(295): MediaWiki->initializeArticle()
#11 /srv/testrepo/w/includes/Wiki.php(555): MediaWiki->performRequest()
#12 /srv/testrepo/w/includes/Wiki.php(448): MediaWiki->main()
#13 /srv/testrepo/w/index.php(59): MediaWiki->run()
#14 {main}
Comment 1 Jeroen De Dauw 2012-12-12 21:47:22 UTC
Some action needs to be taken to prevent this. The reason the wiki thinks it's an item is because it's in an item NS and does not have any page specific content model set. The reason it's not set is because if it's the default, it will not be set, which is the case before you set up the repo. This is a general problem for people changing the default content model of a namespace containing pages of it's default content model, and thus not specific to Wikibase.

A way to fix this would be creating a maintenance script that explicitly sets all content models for pages in a namespace, so the type can safely be switched over.
Comment 2 denny vrandecic 2012-12-13 11:12:09 UTC
Or a script that moves all pages out of the offending-to-be namespace before switching it. A Wikibase installer script could also resolve that (among other things), how it is done in SMW e.g.
Comment 3 Nemo 2013-11-19 12:35:57 UTC
Adding many blockers of bug 38638 to the list of "easy" bugs, to mark them as candidates for [[mw:Google Code-in]] tasks (gci2013). If you think this bug is not suitable, remove the keyword.

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


Navigation
Links