Page MenuHomePhabricator

Wikimedia\Timestamp\TimestampException: Wikimedia\Timestamp\ConvertibleTimestamp::setTimestamp: Invalid timestamp - rccontinue=20220922035158
Closed, ResolvedPublicPRODUCTION ERROR

Description

Error
normalized_message
[{reqId}] {exception_url}   Wikimedia\Timestamp\TimestampException: Wikimedia\Timestamp\ConvertibleTimestamp::setTimestamp: Invalid timestamp - rccontinue=20220922035158
exception.trace
from /srv/mediawiki/php-1.40.0-wmf.5/vendor/wikimedia/timestamp/src/ConvertibleTimestamp.php(257)
#0 /srv/mediawiki/php-1.40.0-wmf.5/vendor/wikimedia/timestamp/src/ConvertibleTimestamp.php(170): Wikimedia\Timestamp\ConvertibleTimestamp->setTimestamp(string)
#1 /srv/mediawiki/php-1.40.0-wmf.5/includes/libs/rdbms/platform/SQLPlatform.php(502): Wikimedia\Timestamp\ConvertibleTimestamp->__construct(string)
#2 /srv/mediawiki/php-1.40.0-wmf.5/includes/libs/rdbms/database/Database.php(3971): Wikimedia\Rdbms\Platform\SQLPlatform->timestamp(string)
#3 /srv/mediawiki/php-1.40.0-wmf.5/includes/libs/rdbms/database/DBConnRef.php(103): Wikimedia\Rdbms\Database->timestamp(string)
#4 /srv/mediawiki/php-1.40.0-wmf.5/includes/libs/rdbms/database/DBConnRef.php(692): Wikimedia\Rdbms\DBConnRef->__call(string, array)
#5 /srv/mediawiki/php-1.40.0-wmf.5/includes/api/ApiQueryRecentChanges.php(141): Wikimedia\Rdbms\DBConnRef->timestamp(string)
#6 /srv/mediawiki/php-1.40.0-wmf.5/includes/api/ApiQueryRecentChanges.php(112): ApiQueryRecentChanges->run()
#7 /srv/mediawiki/php-1.40.0-wmf.5/includes/api/ApiQuery.php(671): ApiQueryRecentChanges->execute()
#8 /srv/mediawiki/php-1.40.0-wmf.5/includes/api/ApiMain.php(1900): ApiQuery->execute()
#9 /srv/mediawiki/php-1.40.0-wmf.5/includes/api/ApiMain.php(875): ApiMain->executeAction()
#10 /srv/mediawiki/php-1.40.0-wmf.5/includes/api/ApiMain.php(846): ApiMain->executeActionWithErrorHandling()
#11 /srv/mediawiki/php-1.40.0-wmf.5/api.php(90): ApiMain->execute()
#12 /srv/mediawiki/php-1.40.0-wmf.5/api.php(45): wfApiMain()
#13 /srv/mediawiki/w/api.php(3): require(string)
#14 {main}
Impact

If I get it right the first issue occurred on enwiki at Oct 18, 2022 @ 12:25:55.665 with URL https://en.wikipedia.org/w/api.php?action=query&format=json&list=recentchanges&rccontinue=rccontinue=rccontinue=20221016184111%7C1560436193&rcdir=newer&rcend=1666095800&rclimit=500&rcstart=1665945000&rctype=edit%7Cnew . Note the parameter that looks like rccontinue=rccontinue=rccontinue=.

I am guessing it is a user in put issue / a Gadget misbehaving. Regardless the TimestampException should be handled?

Notes

Details

Request URL
https://en.wikipedia.org/w/api.php?action=query&format=*&list=*&rccontinue=*&rcdir=*&rcend=*&rclimit=*&rcstart=*&rctype=*

Event Timeline

Change 851144 had a related patch set uploaded (by Umherirrender; author: Umherirrender):

[mediawiki/core@master] api: Validate timestamp in continue parameter

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

Change 851144 merged by jenkins-bot:

[mediawiki/core@master] api: Validate timestamp in continue parameter

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

matmarex removed a project: Patch-For-Review.
matmarex subscribed.