Last modified: 2014-11-15 12:26:56 UTC
When going to https://www.wikidata.org/wiki/Q183 I get the Wikimedia Error Message. If you report this error to the Wikimedia System Administrators, please include the details below. Request: GET http://www.wikidata.org/wiki/Q183, from 10.64.0.103 via cp1053 cp1053 ([10.64.32.105]:3128), Varnish XID 3532046461 Forwarded for: 2620:0:1002:1009:80:a544:b287:e950, 208.80.154.8, 10.64.0.103 Error: 503, Service Unavailable at Wed, 01 Oct 2014 17:44:24 GMT
Confirmed.
Possibly related: https://bugzilla.wikimedia.org/show_bug.cgi?id=61914
Works again... possible I've fixed it by manually pulling it from a text varnish from tin (cp1052), maybe it just fixed itself, who knows.
Possibly a duplicate of bug 71486 ("HHVM http status code 503 on long pages")
Broken again... https://www.wikidata.org/wiki/Wikidata:Administrators%27_noticeboard#Q183
Perhaps due to this is not possible for many users to edit pages in the Russian Wikipedia, which have Germany flag from Wikidata. https://ru.wikipedia.org/wiki/Википедия:Форум/Технический#Не_сохраняются_изменения_в_нескольких_статьях
Updating importance to critical. Unable to edit articles in ruwiki linked to Germany element (confirmed by experiment by unlinking Germany element from article element).
History of Q183 has interesting last edit that labeled with HHVM: https://www.wikidata.org/w/index.php?title=Q183&action=history How do adding of four hieroglyphs can increase page size by 483K?
(In reply to Ilya from comment #8) > How do adding of four hieroglyphs can increase page size by 483K? Well, this is quite simple to explain. There was no edits since July 2014 (because it was not possible to edit Q183 at all). It means Q183 was stored in old serialization format. So latest update not only added 4 chars, but also converted from old small internal format to new "wide" one.
[Setting back to major severity - see https://www.mediawiki.org/wiki/Bugzilla/Fields#Severity for meanings.]
(In reply to Andre Klapper from comment #10) > [Setting back to major severity - see > https://www.mediawiki.org/wiki/Bugzilla/Fields#Severity for meanings.] Andre, inability to edit thousands of articles on Wikipedia seems like "Crashes in a widely used and important component."
Turns out it was impossible to edit any Wikipedia pages that used mw.wikibase.label('Q183') call. Currently workaround for this is implemented on ruwiki, looks like the following: if ( entityId == 'Q183') return '[[Германия]]'; -- do not ask Wikidata for label So importance can be set to major now (from critical). Still unable to edit Wikipedia (!) article [[Германия]] itself (i.e. article linked to Q183 in ruwiki)
*** Bug 71656 has been marked as a duplicate of this bug. ***
*** Bug 71678 has been marked as a duplicate of this bug. ***
Q183 has been temporarily rolled back to a known working version, and superprotected in place. This will allow continued editing of other articles at least, and will avoid 500s when going on the item itself.
*** Bug 71542 has been marked as a duplicate of this bug. ***
Cf. https://www.wikidata.org/w/index.php?title=Wikidata:Project_chat&oldid=162432153#Temporary_protection_of_Q183_.28Germany.29
this can be reproduced with stacktrace, with: $rev = Revision::newFromId( 143201634 ); $content = $rev->getContent(); $pout = $content->getParserOutput( $title ); (consistent with what Tim found) Caught exception InvalidArgumentException: ByPropertyListSerializer can only serialize Traversable objects #0 /srv/mediawiki/php-1.25wmf1/extensions/Wikidata/extensions/Wikibase/lib/includes/serializers/ReferenceSerializer.php(67): Wikibase\Lib\Serializers\ByPropertyListSerializer->getSerialized(-4754039253130543209) #1 /srv/mediawiki/php-1.25wmf1/extensions/Wikidata/extensions/Wikibase/lib/includes/serializers/ClaimSerializer.php(139): Wikibase\Lib\Serializers\ReferenceSerializer->getSerialized(Object(Wikibase\DataModel\Reference)) #2 /srv/mediawiki/php-1.25wmf1/extensions/Wikidata/extensions/Wikibase/lib/includes/serializers/ByPropertyListSerializer.php(80): Wikibase\Lib\Serializers\ClaimSerializer->getSerialized(Object(Wikibase\DataModel\Statement\Statement)) #3 /srv/mediawiki/php-1.25wmf1/extensions/Wikidata/extensions/Wikibase/lib/includes/serializers/ClaimsSerializer.php(60): Wikibase\Lib\Serializers\ByPropertyListSerializer->getSerialized(Object(Wikibase\DataModel\Claim\Claims)) #4 /srv/mediawiki/php-1.25wmf1/extensions/Wikidata/extensions/Wikibase/lib/includes/serializers/EntitySerializer.php(148): ->getSerialized(Object(Wikibase\DataModel\Claim\Claims)) #5 /srv/mediawiki/php-1.25wmf1/extensions/Wikidata/extensions/Wikibase/repo/includes/ParserOutputJsConfigBuilder.php(179): Wikibase\Lib\Serializers\EntitySerializer->getSerialized(Object(Wikibase\DataModel\Entity\Item)) #6 /srv/mediawiki/php-1.25wmf1/extensions/Wikidata/extensions/Wikibase/repo/includes/ParserOutputJsConfigBuilder.php(105): Wikibase\ParserOutputJsConfigBuilder->getSerializedEntity(Object(Wikibase\DataModel\Entity\Item), Object(Wikibase\Lib\Serializers\SerializationOptions)) #7 /srv/mediawiki/php-1.25wmf1/extensions/Wikidata/extensions/Wikibase/repo/includes/ParserOutputJsConfigBuilder.php(82): Wikibase\ParserOutputJsConfigBuilder->getEntityVars(Object(Wikibase\DataModel\Entity\Item), Object(Wikibase\Lib\Serializers\SerializationOptions)) #8 /srv/mediawiki/php-1.25wmf1/extensions/Wikidata/extensions/Wikibase/repo/includes/EntityParserOutputGenerator.php(80): Wikibase\ParserOutputJsConfigBuilder->build(Object(Wikibase\DataModel\Entity\Item), Object(Wikibase\Lib\Serializers\SerializationOptions), false) #9 /srv/mediawiki/php-1.25wmf1/extensions/Wikidata/extensions/Wikibase/repo/includes/content/EntityContent.php(264): Wikibase\EntityParserOutputGenerator->getParserOutput(Object(Wikibase\EntityRevision), true, true) #10 /srv/mediawiki/php-1.25wmf1/extensions/Wikidata/extensions/Wikibase/repo/includes/content/EntityContent.php(210): Wikibase\EntityContent->getParserOutputFromEntityView(Object(Title), NULL, NULL, true) #11 /srv/mediawiki/php-1.25wmf1/maintenance/eval.php(81) : eval()'d code(1): Wikibase\EntityContent->getParserOutput(Object(Title)) #12 /srv/mediawiki/php-1.25wmf1/maintenance/eval.php(81): eval() #13 /srv/mediawiki/multiversion/MWScript.php(97): require_once('/srv/mediawiki/...')
Aude: Is this (the trace you posted) still a problem after tonights deploy?
@hoo still a problem. I am poking at the code now. If the ReferencedEntitiesFinder code is not executed when generating the used entities for parser output js config, then the exception does not occur. I am not sure what the real, actual problem is though, and this might just be a symptom.
Commit pushed to getallsnaks at https://github.com/wmde/WikibaseDataModel https://github.com/wmde/WikibaseDataModel/commit/63d006f4316b32c4089cbf317fa7949cc67c9d2d Call getQualifiers and getReferences outside of iterator_to_array In the getAllSnaks calls in Claim and Statement, it seems in some situations that the Traversable objects are being converted to array, by reference, in the ReferenceList itself and possibly for qualifiers also. This change may help fix bug 71519.
Created attachment 16691 [details] Q183 blob from august 4 dump
Change 165205 had a related patch set uploaded by Aude: Get snaks in ReferenceSerializer from cloned $reference https://gerrit.wikimedia.org/r/165205
I have narrowed down this particular issue (the exception) to the ReferenceSerializer. It calls $reference->getHash() and then the value of the reference's snaks gets corrupt. Before $reference->getHash(), it is: Wikibase\DataModel\Reference::__set_state(array( 'snaks' => Wikibase\DataModel\Snak\SnakList::__set_state(array( 0 => Wikibase\DataModel\Snak\PropertyValueSnak::__set_state(array( 'dataValue' => Wikibase\DataModel\Entity\EntityIdValue::__set_state(array( 'entityId' => Wikibase\DataModel\Entity\ItemId::__set_state(array( 'entityType' => 'item', 'serialization' => 'Q7825', )), )), 'propertyId' => Wikibase\DataModel\Entity\PropertyId::__set_state(array( 'entityType' => 'property', 'serialization' => 'P143', )), )), 1 => Wikibase\DataModel\Snak\PropertyValueSnak::__set_state(array( 'dataValue' => DataValues\StringValue::__set_state(array( 'value' => 'http://www.wto.org/english/thewto_e/whatis_e/tif_e/org6_e.htm', )), 'propertyId' => Wikibase\DataModel\Entity\PropertyId::__set_state(array( 'entityType' => 'property', 'serialization' => 'P854', )), )), 2 => Wikibase\DataModel\Snak\PropertyValueSnak::__set_state(array( 'dataValue' => DataValues\StringValue::__set_state(array( 'value' => 'Germany [Member since] 1 January 1995', )), 'propertyId' => Wikibase\DataModel\Entity\PropertyId::__set_state(array( 'entityType' => 'property', 'serialization' => 'P387', )), )), )), )) after, the reference become: Wikibase\DataModel\Reference::__set_state(array( 'snaks' => -6414602628423053921, )) var_dump of $references (ReferenceList): object(Wikibase\DataModel\ReferenceList)#12660 (1) { ["storage":"SplObjectStorage":private]=> array(3) { ["000000007f160aa30000000042c20a5a"]=> array(2) { ["obj"]=> object(Wikibase\DataModel\Reference)#12659 (1) { ["snaks":"Wikibase\DataModel\Reference":private]=> object(Wikibase\DataModel\Snak\SnakList)#12662 (4) { ["offsetHashes":protected]=> array(0) { } ["acceptDuplicates":protected]=> bool(false) ["indexOffset":protected]=> int(0) ["storage":"ArrayObject":private]=> array(3) { [0]=> object(Wikibase\DataModel\Snak\PropertyValueSnak)#12663 (2) { ["dataValue":"Wikibase\DataModel\Snak\PropertyValueSnak":private]=> object(Wikibase\DataModel\Entity\EntityIdValue)#12664 (1) { ["entityId":"Wikibase\DataModel\Entity\EntityIdValue":private]=> object(Wikibase\DataModel\Entity\ItemId)#12669 (2) { ["entityType":protected]=> string(4) "item" ["serialization":protected]=> string(7) "Q488589" } } ["propertyId":protected]=> object(Wikibase\DataModel\Entity\PropertyId)#12665 (2) { ["entityType":protected]=> string(8) "property" ["serialization":protected]=> string(4) "P143" } } [1]=> object(Wikibase\DataModel\Snak\PropertyValueSnak)#12666 (2) { ["dataValue":"Wikibase\DataModel\Snak\PropertyValueSnak":private]=> object(DataValues\StringValue)#12668 (1) { ["value":protected]=> string(69) "http://www.bmwi.de/DE/Themen/Aussenwirtschaft/Handelspolitik/wto.html" } ["propertyId":protected]=> object(Wikibase\DataModel\Entity\PropertyId)#12667 (2) { ["entityType":protected]=> string(8) "property" ["serialization":protected]=> string(4) "P854" } } [2]=> object(Wikibase\DataModel\Snak\PropertyValueSnak)#12670 (2) { ["dataValue":"Wikibase\DataModel\Snak\PropertyValueSnak":private]=> object(DataValues\StringValue)#12671 (1) { ["value":protected]=> string(177) "Die Welthandelsorganisation ("World Trade Organization" = WTO) wurde 1995 in Genf als Nachfolgerin des sog. GATT-Abkommens ("General Agreement on Tariffs and Trade") gegründet." } ["propertyId":protected]=> object(Wikibase\DataModel\Entity\PropertyId)#12672 (2) { ["entityType":protected]=> string(8) "property" ["serialization":protected]=> string(4) "P387" } } } } } ["inf"]=> NULL } ["000000007f160a510000000042c20a5a"]=> array(2) { ["obj"]=> object(Wikibase\DataModel\Reference)#12673 (1) { ["snaks":"Wikibase\DataModel\Reference":private]=> int(8388544345007956479) } ["inf"]=> NULL } ["000000007f160a5d0000000042c20a5a"]=> array(2) { ["obj"]=> object(Wikibase\DataModel\Reference)#12685 (1) { ["snaks":"Wikibase\DataModel\Reference":private]=> object(Wikibase\DataModel\Snak\SnakList)#12686 (4) { ["offsetHashes":protected]=> array(0) { } ["acceptDuplicates":protected]=> bool(false) ["indexOffset":protected]=> int(0) ["storage":"ArrayObject":private]=> array(3) { [0]=> object(Wikibase\DataModel\Snak\PropertyValueSnak)#12687 (2) { ["dataValue":"Wikibase\DataModel\Snak\PropertyValueSnak":private]=> object(Wikibase\DataModel\Entity\EntityIdValue)#12688 (1) { ["entityId":"Wikibase\DataModel\Entity\EntityIdValue":private]=> object(Wikibase\DataModel\Entity\ItemId)#12693 (2) { ["entityType":protected]=> string(4) "item" ["serialization":protected]=> string(7) "Q520524" } } ["propertyId":protected]=> object(Wikibase\DataModel\Entity\PropertyId)#12689 (2) { ["entityType":protected]=> string(8) "property" ["serialization":protected]=> string(4) "P143" } } [1]=> object(Wikibase\DataModel\Snak\PropertyValueSnak)#12690 (2) { ["dataValue":"Wikibase\DataModel\Snak\PropertyValueSnak":private]=> object(DataValues\StringValue)#12692 (1) { ["value":protected]=> string(73) "http://www.bpb.de/wissen/1V2YPW,0,0,WTO_%96_World_Trade_Organization.html" } ["propertyId":protected]=> object(Wikibase\DataModel\Entity\PropertyId)#12691 (2) { ["entityType":protected]=> string(8) "property" ["serialization":protected]=> string(4) "P854" } } [2]=> object(Wikibase\DataModel\Snak\PropertyValueSnak)#12694 (2) { ["dataValue":"Wikibase\DataModel\Snak\PropertyValueSnak":private]=> object(DataValues\StringValue)#12695 (1) { ["value":protected]=> string(39) "Deutschland [Mitglied seit] Januar 1995" } ["propertyId":protected]=> object(Wikibase\DataModel\Entity\PropertyId)#12696 (2) { ["entityType":protected]=> string(8) "property" ["serialization":protected]=> string(4) "P387" } } } } } ["inf"]=> NULL } } }
https://github.com/wikimedia/mediawiki-extensions-Wikibase/blob/master/lib/includes/serializers/ReferenceSerializer.php#L58-L67 is the code in question
Change 165397 had a related patch set uploaded by Aude: Get snaks in ReferenceSerializer from cloned $reference https://gerrit.wikimedia.org/r/165397
Change 165397 merged by jenkins-bot: Get snaks in ReferenceSerializer from cloned $reference https://gerrit.wikimedia.org/r/165397
Change 165406 had a related patch set uploaded by Aude: Update Wikidata with patch to help address bug 71519 https://gerrit.wikimedia.org/r/165406
Change 165406 merged by jenkins-bot: Update Wikidata with patch to help address bug 71519 https://gerrit.wikimedia.org/r/165406
Change 165409 had a related patch set uploaded by Aude: Update Wikidata with patch to help address bug 71519 https://gerrit.wikimedia.org/r/165409
Change 165410 had a related patch set uploaded by Aude: Update Wikidata with patch to help address bug 71519 https://gerrit.wikimedia.org/r/165410
Change 165409 merged by jenkins-bot: Update Wikidata with patch to help address bug 71519 https://gerrit.wikimedia.org/r/165409
Change 165410 merged by jenkins-bot: Update Wikidata with patch to help address bug 71519 https://gerrit.wikimedia.org/r/165410
now we get: Catchable fatal error: Argument 1 passed to iterator_to_array() must implement interface Traversable, array given, called in /srv/mediawiki/php-1.25wmf2/extensions/Wikidata/vendor/wikibase/data-model/src/Entity/Entity.php on line 468 and defined at /srv/mediawiki/php-1.25wmf2/extensions/Wikidata/vendor/wikibase/data-model/src/Statement/Statement.php on line 129 #0 /srv/mediawiki/php-1.25wmf2/extensions/Wikidata/vendor/wikibase/data-model/src/Statement/Statement.php(129): iterator_to_array(Array) #1 /srv/mediawiki/php-1.25wmf2/extensions/Wikidata/vendor/wikibase/data-model/src/Entity/Entity.php(468): Wikibase\DataModel\Statement\Statement->getAllSnaks() #2 /srv/mediawiki/php-1.25wmf2/extensions/Wikidata/extensions/Wikibase/repo/includes/EntityParserOutputGenerator.php(83): Wikibase\DataModel\Entity\Entity->getAllSnaks() #3 /srv/mediawiki/php-1.25wmf2/extensions/Wikidata/extensions/Wikibase/repo/includes/content/EntityContent.php(264): Wikibase\EntityParserOutputGenerator->getParserOutput(Object(Wikibase\EntityRevision), false, true) #4 /srv/mediawiki/php-1.25wmf2/extensions/Wikidata/extensions/Wikibase/repo/includes/content/EntityContent.php(210): Wikibase\EntityContent->getParserOutputFromEntityView(Object(Title), 143201634, Object(ParserOptions), true) #5 /srv/mediawiki/php-1.25wmf2/includes/poolcounter/PoolWorkArticleView.php(139): Wikibase\EntityContent->getParserOutput(Object(Title), 143201634, Object(ParserOptions)) #6 /srv/mediawiki/php-1.25wmf2/includes/poolcounter/PoolCounterWork.php(123): PoolWorkArticleView->doWork() #7 /srv/mediawiki/php-1.25wmf2/includes/page/Article.php(688): PoolCounterWork->execute() #8 /srv/mediawiki/php-1.25wmf2/extensions/Wikidata/extensions/Wikibase/repo/includes/actions/ViewEntityAction.php(202): Article->view() #9 /srv/mediawiki/php-1.25wmf2/extensions/Wikidata/extensions/Wikibase/repo/includes/actions/ViewEntityAction.php(126): Wikibase\ViewEntityAction->displayEntityContent(Object(Wikibase\ItemContent)) #10 /srv/mediawiki/php-1.25wmf2/includes/MediaWiki.php(414): Wikibase\ViewEntityAction->show() #11 /srv/mediawiki/php-1.25wmf2/includes/MediaWiki.php(282): MediaWiki->performAction(Object(Article), Object(Title)) #12 /srv/mediawiki/php-1.25wmf2/includes/MediaWiki.php(584): MediaWiki->performRequest() #13 /srv/mediawiki/php-1.25wmf2/includes/MediaWiki.php(435): MediaWiki->main() #14 /srv/mediawiki/php-1.25wmf2/index.php(46): MediaWiki->run() #15 /srv/mediawiki/w/index.php(3): require('/srv/mediawiki/...') https://github.com/wmde/WikibaseDataModel/pull/216 or such might be the solution, although again odd that this is happening at all. Only on Q183!
regarding comment #34, seems very similar to the issue we had with Q72 (bug 71479)
Running it via Apache, I get a crash in Wikibase\DataModel\ByPropertyIdArray::buildIndex() during garbage collection. PHP backtrace: #0: Wikibase\DataModel\ByPropertyIdArray::buildIndex #1: Wikibase\DataModel\ByPropertyIdArray::buildIndex #2: Wikibase\Lib\Serializers\ByPropertyListSerializer::getSerialized #3: Wikibase\Lib\Serializers\ClaimSerializer::getQualifiersSerialization #4: Wikibase\Lib\Serializers\ClaimSerializer::getSerialized #5: Wikibase\Lib\Serializers\ByPropertyListSerializer::getSerialized #6: Wikibase\Lib\Serializers\ClaimsSerializer::getSerialized #7: Wikibase\Lib\Serializers\EntitySerializer::getSerialized #8: Wikibase\ParserOutputJsConfigBuilder::getSerializedEntity #9: Wikibase\ParserOutputJsConfigBuilder::getEntityVars #10: Wikibase\ParserOutputJsConfigBuilder::build #11: Wikibase\EntityParserOutputGenerator::getParserOutput #12: Wikibase\EntityContent::getParserOutputFromEntityView #13: Wikibase\EntityContent::getParserOutput #14: PoolWorkArticleView::doWork #15: PoolCounterWork::execute #16: Article::view #17: Wikibase\ViewEntityAction::displayEntityContent #18: Wikibase\ViewEntityAction::show #19: MediaWiki::performAction #20: MediaWiki::performRequest #21: MediaWiki::main #22: MediaWiki::run #23: file: /srv/mediawiki/php-1.25wmf2/index.php C backtrace: #0 zval_mark_grey (pz=0x7feaa1f597d0) at /tmp/buildd/php5-5.3.10/Zend/zend_gc.c:352 #1 0x00007fea99b72709 in gc_collect_cycles () at /tmp/buildd/php5-5.3.10/Zend/zend_gc.c:405 #2 0x00007fea99b72974 in gc_zval_possible_root (zv=0x7feaa1f597d0) at /tmp/buildd/php5-5.3.10/Zend/zend_gc.c:166 #3 0x00007fea99bd6a69 in ZEND_ASSIGN_DIM_SPEC_VAR_UNUSED_HANDLER (execute_data=0x7feaa2ea17f8) at /tmp/buildd/php5-5.3.10/Zend/zend_gc.h:183 #4 0x00007fea99b7ab7b in execute (op_array=0x7fea9f252a18) at /tmp/buildd/php5-5.3.10/Zend/zend_vm_execute.h:107
Change 165205 merged by jenkins-bot: Get snaks in ReferenceSerializer from cloned $reference https://gerrit.wikimedia.org/r/165205
I can reproduce the segfault in eval.php --wiki=wikidatawiki with: $req = new FauxRequest(array('oldid'=>143201634)); $req->setRequestURL('http://www.wikidata.org/w/index.php?title=Q183&oldid=143201634'); $ctx = new RequestContext; $ctx->setRequest($req); $mw = new MediaWiki($ctx); $mw->run(); By parsing, I only get a fatal error, not a segfault.
Further reduced test case: $entity = unserialize(file_get_contents('/tmp/q183-entity.ser')); $sf = new Wikibase\Lib\Serializers\SerializerFactory; $sr = $sf->newSerializerForEntity('item',new Wikibase\Lib\Serializers\SerializationOptions); hebrev(''); $sr->getSerialized($entity); str_shuffle(''); $sr->getSerialized($entity); ...where q183-entity.ser is a file generated by serializing the Entity. It crashes on the second getSerialized() call.
[No patches left to review; resetting bug status to NEW]