Page MenuHomePhabricator

Release a new version of Timestamp
Closed, ResolvedPublic

Description

As part of r884063 (part of Growth-Positive-Reinforcement, an ongoing Growth-Team project), being able to do ConvertibleTimestamp::time()->sub(...) would come useful (added in 09b22e4600). Let's do a new release of the library, which would include the following patches:

as well as some require-dev bumps by libraryupgrader. AFAICS, there is no breaking change involved, merely new methods/new optional parameters => let's go for 4.1.0 as the new version.

Event Timeline

Restricted Application added a subscriber: Aklapper. · View Herald Transcript

Change 888820 had a related patch set uploaded (by Urbanecm; author: Urbanecm):

[mediawiki/libs/Timestamp@master] Release v4.1.0

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

Change 888820 merged by jenkins-bot:

[mediawiki/libs/Timestamp@master] Release v4.1.0

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

Change 888825 had a related patch set uploaded (by Urbanecm; author: Urbanecm):

[mediawiki/vendor@master] Update ConvertibleTimestamp to 4.1.0

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

Change 888826 had a related patch set uploaded (by Urbanecm; author: Urbanecm):

[mediawiki/core@master] Update ConvertibleTimestamp to 4.1.0

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

Change 889064 had a related patch set uploaded (by Urbanecm; author: Urbanecm):

[mediawiki/libs/Timestamp@master] Do not cast fake time callable to int

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

Change 889064 abandoned by Urbanecm:

[mediawiki/libs/Timestamp@master] Do not cast fake time callable to int

Reason:

replaced with I82d49a5e3a52c14dbd7e5324eb4c75cf7c33f3d2

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

Note that similar setMockTime methods such as on BagOStuff and WANObjectCache accept a by-ref microtime-like float. This could potentially be applied to Timestamp as well, with the value casted to int by the internal consumer within the Timestamp library when it needs a whole second value.

On the other hand, I actually quite like the strictness of permitting whole integers only since indeed almost everything we do in MW is only sensitive to expiry dates or formatted timestamps, both of which utilize whole seconds only. And with clockskew etc it seems rather questionable anyway to rely on milliseconds for unit test correctness.

Change 888825 merged by jenkins-bot:

[mediawiki/vendor@master] Update ConvertibleTimestamp to 4.1.0

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

Change 888826 merged by jenkins-bot:

[mediawiki/core@master] Update ConvertibleTimestamp to 4.1.0

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

Uses that should be bumped:

Change 954082 had a related patch set uploaded (by Urbanecm; author: Urbanecm):

[mediawiki/extensions/Wikibase@master] Bump wikimedia/timestamp to 4.1.0

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

Use in mediawiki/libs/metrics-platform remains unpatched.

Change 954100 had a related patch set uploaded (by Urbanecm; author: Urbanecm):

[mediawiki/libs/metrics-platform@master] Bump wikimedia/timestamp to 4.1.0

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

Use in mediawiki/libs/metrics-platform remains unpatched.

Not as a result of this library release though: it currently requires 3.0.0, even though 4.0.0 was released in Mar 2022, almost a year before my Feb 2023 release. Uploaded a bumping patch though.

Use in mediawiki/libs/metrics-platform remains unpatched.

Not as a result of this library release though: it currently requires 3.0.0, even though 4.0.0 was released in Mar 2022, almost a year before my Feb 2023 release. Uploaded a bumping patch though.

Hmm, yes, EventLogging is using v2.0.0 which is from February. Not sure how this doesn't fatal currently?

Hmm, yes, EventLogging is using v2.0.0 which is from February. Not sure how this doesn't fatal currently?

That's wikimedia/metrics-platform, not timestamp, and it appears to be the newest available release? Why should it fatal?

Hmm, yes, EventLogging is using v2.0.0 which is from February. Not sure how this doesn't fatal currently?

That's wikimedia/metrics-platform, not timestamp, and it appears to be the newest available release? Why should it fatal?

EL is depending on a library which requires Timestamp 3.x but in production it's loaded alongside Timestamp 4.x and /vendor doesn't complain about mis-matched dependencies?

Change 954100 merged by jenkins-bot:

[mediawiki/libs/metrics-platform@master] Bump wikimedia/timestamp to 4.1.0

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

Change 954082 merged by jenkins-bot:

[mediawiki/extensions/Wikibase@master] Bump wikimedia/timestamp to 4.1.0

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