Page MenuHomePhabricator

quibble-vendor-mysql-hhvm-docker failure for UserMerge
Closed, ResolvedPublic

Description

Spotted while testing https://gerrit.wikimedia.org/r/#/c/431485/

Stacktrace can be found at https://integration.wikimedia.org/ci/job/quibble-vendor-mysql-hhvm-docker/1227/console and error details copied below as follows:

23:16:55 1) MergeUserTest::testDeleteUser
23:16:55 Wikimedia\Rdbms\DBQueryError: A database query error has occurred. Did you forget to run your application's database schema updater after upgrading? 
23:16:55 Query: UPDATE  `unittest_site_stats` SET ss_users=ss_users-1
23:16:55 Function: SiteStatsUpdate::tryDBUpdateInternal
23:16:55 Error: 1690 BIGINT UNSIGNED value is out of range in '(`wikidb`.`unittest_site_stats`.`ss_users` - 1)' (/tmp/quibble-mysql-5gyps4x0/socket)
23:16:55 
23:16:55 
23:16:55 /workspace/src/includes/libs/rdbms/database/Database.php:1449
23:16:55 /workspace/src/includes/libs/rdbms/database/Database.php:1419
23:16:55 /workspace/src/includes/libs/rdbms/database/Database.php:1192
23:16:55 /workspace/src/includes/libs/rdbms/database/Database.php:2060
23:16:55 /workspace/src/includes/deferred/SiteStatsUpdate.php:132
23:16:55 /workspace/src/includes/deferred/MWCallableUpdate.php:34
23:16:55 /workspace/src/includes/deferred/DeferredUpdates.php:268
23:16:55 /workspace/src/includes/deferred/DeferredUpdates.php:226
23:16:55 /workspace/src/includes/deferred/DeferredUpdates.php:134
23:16:55 /workspace/src/includes/deferred/DeferredUpdates.php:307
23:16:55 /workspace/src/includes/deferred/DeferredUpdates.php:100
23:16:55 /workspace/src/extensions/UserMerge/MergeUser.php:514
23:16:55 /workspace/src/extensions/UserMerge/MergeUser.php:61
23:16:55 /workspace/src/extensions/UserMerge/tests/phpunit/MergeUserTest.php:73
23:16:55 /workspace/src/tests/phpunit/MediaWikiTestCase.php:423
23:16:55 /workspace/src/maintenance/doMaintenance.php:94

Event Timeline

Restricted Application added a subscriber: Aklapper. · View Herald TranscriptMay 7 2018, 10:26 AM
hashar added a comment.May 7 2018, 7:23 PM

I migrated that extension since the job passed https://integration.wikimedia.org/ci/job/quibble-vendor-mysql-php70-docker/1478/ albeit using php7. And indeed on that job the database error log (mw-dberror.log) had:

Sun Apr 29 10:28:02 UTC 2018	83b9d77188b9	wikidb-unittest_	
SiteStatsUpdate::tryDBUpdateInternal	localhost:/tmp/quibble-mysql-o343v4rv/socket
1690	BIGINT UNSIGNED value is out of range in '(`wikidb`.`unittest_site_stats`.`ss_users` - 1)'
(localhost:/tmp/quibble-mysql-o343v4rv/socket)	UPDATE  `unittest_site_stats` SET ss_users=ss_users-1

The reason is the database is now configured to emit an error instead of a warning. That is T119371: Enable MariaDB/MySQL strict mode for MW during development and Jenkins jobs asking to use strict mode (sql_mode = 'TRADITIONAL') which catch more issues.

So the test is broken here. Maybe ss_users is at zero and lowering it by one is an error since the field is unsigned.

Change 435944 had a related patch set uploaded (by Legoktm; owner: Legoktm):
[mediawiki/extensions/UserMerge@master] tests: Increment site_stats when creating a new user

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

Change 435944 merged by jenkins-bot:
[mediawiki/extensions/UserMerge@master] tests: Increment site_stats when creating a new user

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

Legoktm closed this task as Resolved.May 29 2018, 1:46 AM
Legoktm claimed this task.
Vvjjkkii renamed this task from quibble-vendor-mysql-hhvm-docker failure for UserMerge to xhdaaaaaaa.Jul 1 2018, 1:11 AM
Vvjjkkii reopened this task as Open.
Vvjjkkii removed Legoktm as the assignee of this task.
Vvjjkkii triaged this task as High priority.
Vvjjkkii updated the task description. (Show Details)
Vvjjkkii edited subscribers, added: Legoktm; removed: gerritbot, Aklapper, MarcoAurelio.
CommunityTechBot renamed this task from xhdaaaaaaa to quibble-vendor-mysql-hhvm-docker failure for UserMerge.Jul 2 2018, 4:23 PM
CommunityTechBot closed this task as Resolved.
CommunityTechBot assigned this task to Legoktm.
CommunityTechBot raised the priority of this task from High to Needs Triage.
CommunityTechBot updated the task description. (Show Details)
CommunityTechBot edited subscribers, added: gerritbot, Aklapper, MarcoAurelio; removed: Legoktm.