Page MenuHomePhabricator

Introduce separate messages for range violations involving current time
Closed, ResolvedPublic

Description

Instead of injecting the current date and time into the regular “range” violation messages, let’s add separate messages for “now” range endpoints. This means we can cache the violation message for as long as it’s valid, and will probably also make for easier-to-understand violation messages.

(An alternative approach to solve the caching problem would be to store “current time” as a special value in ViolationMessage arguments, and resolve it in the renderer, but I think the other benefits of having separate messages are clear enough that it’s worth pursuing this path instead.)

Event Timeline

Change 410493 had a related patch set uploaded (by Lucas Werkmeister (WMDE); owner: Lucas Werkmeister (WMDE)):
[mediawiki/extensions/WikibaseQualityConstraints@master] Reject ranges with same endpoints

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

Change 410494 had a related patch set uploaded (by Lucas Werkmeister (WMDE); owner: Lucas Werkmeister (WMDE)):
[mediawiki/extensions/WikibaseQualityConstraints@master] Add separate range messages for “now” endpoints

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

Change 410493 merged by jenkins-bot:
[mediawiki/extensions/WikibaseQualityConstraints@master] Reject ranges with same endpoints

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

Change 410494 merged by jenkins-bot:
[mediawiki/extensions/WikibaseQualityConstraints@master] Add separate range messages for “now” endpoints

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