Page MenuHomePhabricator

IPReveal: Remove the revision endpoint and use the batch mechanism instead
Closed, ResolvedPublic1.5 Estimated Story Points

Description

Summary

  • After CheckUser patch #1167909, IP reveals in Special:Contributions are using the batch endpoint (i.e. a POST request).
  • The same mechanism should be used for codepaths currently using the revision endpoint, which would allow to remove that endpoint.

Background

Acceptance criteria

  • The revision endpoint is removed
  • Codepaths currently using the revision endpoint use the batch endpoint instead

Event Timeline

Tchanders set the point value for this task to 0.5.Jul 29 2025, 6:32 AM

I'm happy to pick up this ticket, but I prefer to do so after https://gerrit.wikimedia.org/r/c/mediawiki/extensions/CheckUser/+/1171567 gets merged so we don't lose time handling merge conflicts in the IP Reveal code (this will require changes in modules/ext.checkUser.tempAccounts/rest.js which is already being modified in that patch, which is currently in review).

Filed T400901: Replace usages of CheckUser's /revision endpoint with /batch-temporaryaccount for replacing usages of the /revision endpoint in PageTriage, which is needed in order to completely drop the endpoint in CheckUser.

Change #1174735 had a related patch set uploaded (by Harroyo-wmf; author: Harroyo-wmf):

[mediawiki/extensions/CheckUser@master] ipreveal. Deprecate the IPReveal revision endpoint

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

Change #1174735 merged by jenkins-bot:

[mediawiki/extensions/CheckUser@master] ipreveal. Deprecate the IPReveal revision endpoint

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

hector.arroyo changed the task status from Open to Stalled.EditedAug 1 2025, 10:57 AM

An initial patch has been merged that tags the TemporaryAccountRevisionHandler as deprecated and removes a code path from the frontend code that was already unreachable.

However, the removal of the endpoint itself cannot happen until T400901: Replace usages of CheckUser's /revision endpoint with /batch-temporaryaccount is handled by PageTriage maintainers, therefore I'm moving this task back to the Backlog.

Dreamy_Jazz changed the task status from Stalled to Open.Nov 6 2025, 5:42 PM

Looks like https://gerrit.wikimedia.org/r/plugins/gitiles/mediawiki/extensions/CheckUser/+/refs/heads/master/modules/ext.checkUser.tempAccounts/rest.js#106 still calls /checkuser/v0/temporaryaccount/${target} instead of using the batch endpoint, but we should be able to tackle that as part of this task. My fault, that's not the revisions endpoint. In any case, usages left in CheckUser (i.e. mocks from tests) have been removed under T413441: IPReveal: Remove usages of the revision endpoint left in CheckUser.

Codesearch does not list any other usages of that endpoint besides the one mentioned above: https://codesearch.wmcloud.org/search/?q=%2Fcheckuser%2Fv0%2Ftemporaryaccount%2F&files=&excludeFiles=&repos=

Change #1220641 had a related patch set uploaded (by Harroyo-wmf; author: Harroyo-wmf):

[mediawiki/extensions/CheckUser@master] ipreveal: Remove the revisions endpoint

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

As part of this task, I've updated the tests for BatchTemporaryAccountHandlerTest in order to cover some of the cases previously covered by TemporaryAccountRevisionHandler tests, which are now being dropped along with TemporaryAccountRevisionHandler itself.

Raising the estimation for this task.

hector.arroyo changed the point value for this task from 0.5 to 1.5.Jan 5 2026, 3:38 PM

Change #1220641 merged by jenkins-bot:

[mediawiki/extensions/CheckUser@master] ipreveal: Remove the revisions endpoint

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