Page MenuHomePhabricator

Fatal error: CachingEntityRevisionLookup.php on line 129
Closed, ResolvedPublicPRODUCTION ERROR

Description

On Logstash for the Beta-Cluster-Infrastructure there's:

Fatal error: Call to undefined method __PHP_Incomplete_Class::getRevisionId() in /srv/mediawiki/php-master/extensions/Wikidata/extensions/Wikibase/lib/includes/Store/CachingEntityRevisionLookup.php on line 129

logstash

Event Timeline

Restricted Application added a project: User-MarcoAurelio. · View Herald TranscriptAug 5 2017, 4:13 PM
Restricted Application added subscribers: PokestarFan, Aklapper. · View Herald Transcript

Now also:

Fatal error: Call to undefined method __PHP_Incomplete_Class::getRevisionId() in /srv/mediawiki/php-master/extensions/Wikidata/extensions/Wikibase/lib/includes/Store/CachingEntityRevisionLookup.php on line 130

link

In the past 30 days there was only 84 cases of this error in timespan of less than 12 hours see the report. I'm guessing this is only because of an outage in beta cluster (which happens a lot) or any other reasons related to beta cluster being unstable (by nature). I couldn't find any case of this happening in production. I'm inclined to close this but I wait for feedback :)

aude added a comment.Aug 7 2017, 12:31 PM

this happened when the build got deployed.

aude triaged this task as High priority.Aug 7 2017, 12:31 PM
hoo added a subscriber: hoo.EditedAug 9 2017, 8:01 PM

I couldn't find any instance of this in production.

This usually happens when a class is mentioned in a serialized object which can't be autoloaded/ is not known.

$ php -a
php > class foobar {};
php > $foobar = new foobar();
php > echo serialize( $foobar );
O:6:"foobar":0:{}
$ php -a
php > var_dump(unserialize('O:6:"foobar":0:{}'));
php shell code:1:
class __PHP_Incomplete_Class#1 (1) {
  public $__PHP_Incomplete_Class_Name =>
  string(6) "foobar"
}

Given none of the relevant classes have been moved lately (I hope), I guess this is some beta-only php autoloader-bytecode-cache screweup which will not happen in production (given we put a new autoloader class in place there after every deploy).

So I deployed a new build to the beta cluster an hour or so ago, so lets see if we spot this at all.

aude added a comment.EditedAug 9 2017, 8:44 PM

@hoo this issue / code never made it to production yet

The error is back and hitting hard on fatalmonitor@logstash-beta: 46 and increasing.

@hoo: actually my guess was the autoloader glitch was somewhat related to https://gerrit.wikimedia.org/r/#/c/370157/. At least dates seem to match?
But I couldn't really find why this mass move would cause any issue, so not sure.

aude added a comment.Aug 9 2017, 8:53 PM

it's probably somethign in property suggester or one of those extensions

Change 370949 had a related patch set uploaded (by WMDE-leszek; owner: WMDE-leszek):
[mediawiki/extensions/Wikibase@master] Temporarily add class alias for EntityRevision

https://gerrit.wikimedia.org/r/370949

So things are stored in the cache for 1 hour.
Things that are uncached can not be because the class alias does not exist.
So if we left this on beta for 1 hour then it would actually 'fix' itself, but the same issue would happen in production.

We will have to add an alias (and do ugly fixes in the files in the Wikibase namespace that use the class) and then remove this a while after it has been deployed everywhere

So the build have been reverted again now, and beta may see 1 more hour of fatals.
The build tomorrow will include the patch above which should prevent the fatals, and we will see this when we merge the build tomorrow.

Addshore claimed this task.Aug 9 2017, 10:54 PM
Addshore added a project: User-Addshore.
Addshore moved this task from Unsorted 💣 to Back Burner 🏛️ on the User-Addshore board.

Change 370949 merged by jenkins-bot:
[mediawiki/extensions/Wikibase@master] Temporarily add class alias for EntityRevision

https://gerrit.wikimedia.org/r/370949

Seems https://gerrit.wikimedia.org/r/370949 fixed the issue.
The class alias introduced in https://gerrit.wikimedia.org/r/370949 should be removed in the next deployment after the one which includes https://gerrit.wikimedia.org/r/370949 (I mean production deployments). That way there should be no issues when Wikibase is updated on production.

Addshore closed this task as Resolved.Aug 10 2017, 5:53 PM
Addshore moved this task from Back Burner 🏛️ to Closing ✔️ on the User-Addshore board.

Change 372520 had a related patch set uploaded (by WMDE-leszek; owner: WMDE-leszek):
[mediawiki/extensions/Wikibase@master] Remove no longer needed EntityRevision alias

https://gerrit.wikimedia.org/r/372520

Change 372520 merged by jenkins-bot:
[mediawiki/extensions/Wikibase@master] Remove no longer needed EntityRevision alias

https://gerrit.wikimedia.org/r/372520

mmodell changed the subtype of this task from "Task" to "Production Error".Aug 28 2019, 11:10 PM