Page MenuHomePhabricator

Wikimedia\Timestamp\TimestampException: Wikimedia\Timestamp\ConvertibleTimestamp::setTimestamp: Invalid timestamp - 2008-08-13ᑦ22:45:00.000z
Closed, ResolvedPublicPRODUCTION ERROR

Description

Can reproduce with:

https://iu.wikipedia.org/w/index.php?title=%E1%90%85%E1%90%83%E1%91%AD%E1%90%B1%E1%91%8E%E1%90%8A:%E1%90%B9%E1%95%90%E1%93%82%E1%96%85&variant=ike-cans&useparsoid=1&parsoidnewlc=1

Also
https://sr.wikipedia.org/sr-ec/User_Talk:Pidor003?useparsoid=1&parsoidnewlc=1
https://logstash.wikimedia.org/app/discover#/doc/logstash-*/logstash-deploy-1-7.0.0-1-2026.03.06?id=pTIBxJwBlLUf3R62Zg4U

Looks like the variant of the timestamp is causing issues with DiscussionTools' date (un)formatting?

Error
  • mwversion: 1.46.0-wmf.18
  • timestamp: 2026-03-06T16:28:13.864Z
  • phpversion: 8.3.30
  • reqId: 590c0328-168f-46b7-a4d1-064d721caec8
  • Find reqId in Logstash
normalized_message
[{reqId}] {exception_url}   Wikimedia\Timestamp\TimestampException: Wikimedia\Timestamp\ConvertibleTimestamp::setTimestamp: Invalid timestamp - 2008-08-13ᑦ22:45:00.000z
FrameLocationCall
from/srv/mediawiki/php-1.46.0-wmf.18/vendor/wikimedia/timestamp/src/ConvertibleTimestamp.php(312)
#0/srv/mediawiki/php-1.46.0-wmf.18/vendor/wikimedia/timestamp/src/ConvertibleTimestamp.php(222)Wikimedia\Timestamp\ConvertibleTimestamp->setTimestamp(string)
#1/srv/mediawiki/php-1.46.0-wmf.18/extensions/DiscussionTools/includes/CommentFormatter.php(746)Wikimedia\Timestamp\ConvertibleTimestamp->__construct(string)
#2/srv/mediawiki/php-1.46.0-wmf.18/extensions/DiscussionTools/includes/BatchModifyElements.php(43)MediaWiki\Extension\DiscussionTools\CommentFormatter::MediaWiki\Extension\DiscussionTools\{closure}(Wikimedia\RemexHtml\Serializer\SerializerNode)
#3/srv/mediawiki/php-1.46.0-wmf.18/includes/Html/HtmlHelperTrait.php(42)MediaWiki\Extension\DiscussionTools\BatchModifyElements->MediaWiki\Extension\DiscussionTools\{closure}(Wikimedia\RemexHtml\Serializer\SerializerNode)
#4/srv/mediawiki/php-1.46.0-wmf.18/vendor/wikimedia/remex-html/src/Serializer/Serializer.php(289)Wikimedia\RemexHtml\Serializer\HtmlFormatter@anonymous
Impact
Notes

Details

Request URL
https://logstash.wikimedia.org/app/dashboards#/doc/logstash-*/logstash-deploy-1-7.0.0-1-2026.03.06?id=Byz6w5wBlLUf3R62aUpE
Related Changes in Gerrit:

Event Timeline

Why is there a "ᑦ" in the timestamp? That's U+1466 CANADIAN SYLLABICS T. There should be a normal ASCII T at that position.

Because that’s what the &variant=ike-cans URL parameter asks for. CommentFormatter.php:746 tries to interpret a title HTML attribute – it’s absolutely reasonable from LanguageConverter to convert title attributes, since they are meant to be human-readable, not machine-readable. Could DiscussionTools use a data- attribute instead for storing machine-readable data?

Ironically, a few lines above in LanguageConverter.php says "HTML markups (anything between < and >)" is not converted.

All of the test URLs have ?parsoidnewlc=1 which is from the experimental new parsoid language converter support and are being triggered from our visualdiff testing. I don't believe this affects ordinary readers, as we haven't turned on the new parsoid language converter implementation yet.

Yes, machine-readable dates was part of the idea behind https://cscott.net/wiki/index.php/Ideas/A_Dozen_Visions_for_Wikitext/Syntax_for_Discussions but it was never implemented, alas.

Change #1253652 had a related patch set uploaded (by Bartosz Dziewoński; author: Bartosz Dziewoński):

[mediawiki/extensions/DiscussionTools@master] CommentFormatter: Fix bad interaction of 'title' attribute with language converter

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

Change #1253652 merged by jenkins-bot:

[mediawiki/extensions/DiscussionTools@master] CommentFormatter: Fix bad interaction of 'title' attribute with language converter

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

matmarex claimed this task.