Page MenuHomePhabricator

Temporary account IP reveal: Display "no longer available" instead of "unavailable" when IP reveal fails due to data having expired
Closed, ResolvedPublic1 Estimated Story Points

Description

Summary

The CheckUser temporary account IP reveal feature currently displays "unavailable" when no IP could be found, including in the case when the IP has expired. When the IP has expired we should instead display "no longer available" to improve understandability.

Background

  • Temporary account IP reveal provided by CheckUser adds a "Show IP" button
    • This button when pressed is replaced with the IP address associated with the action performed by the temporary account
    • When this IP address cannot be found, the text "unavailable" instead is what is shown
  • The IP address can be not found if it has expired due to being older than 3 months
    • When this occurs, the same "unavailable" message is shown
    • It has been noted by a WMF steward that using this message text isn't clear, as it could imply that the IP address was never unavailable. Instead using something like "no longer available" makes it clear the IP is not found because it has expired

User story

  • As a user with IP reveal rights, I click "Show IP" for a temporary account which last edited over 3 months ago
  • I see the button be replaced with the text "unavailable"
  • I am confused as to why the IP address is not available

Technical notes

  • We could probably just determine if "no longer available" is to be displayed if the timestamp associated with the action we are revealing the IP for is over 3 months old
    • Importantly, the 3 months old cutoff comes from the $wgCUDMaxAge configuration value which is set by default to 3 months

Acceptance criteria

  • When IP reveal fails due to the IP having expired, the message "no longer available" is shown instead of "unavailable"

Event Timeline

Tchanders set the point value for this task to 1.Aug 1 2025, 1:11 PM

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

[mediawiki/extensions/CheckUser@master] ipreveal: Show a different error message for when data has expired

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

Note it doesn't seem possible to support this properly in Special:Log when revealing an IP for the first time until T399712: IPReveal: Remove the log endpoint and use the batch mechanism instead gets done and makes that page use the batch endpoint instead of /v0/temporaryaccount/~2025-123/logs/123: When the local storage is empty, clicking to show an IP for the first time still shows "unavailable" instead of "no longer available".

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

[mediawiki/extensions/CheckUser@master] ipreveal: Show a different error message when data has expired

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

As agreed, I'm reworking the former patch, splitting it into separate patches first and then reworking the former one, so moving this back to 'In Progress'.

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

[mediawiki/extensions/CheckUser@master] ipreveal: Remove rexpired IDs from responses of the batch endpoint

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

Change #1180875 merged by jenkins-bot:

[mediawiki/extensions/CheckUser@master] ipreveal: Service for determining if IP data is expired by log ID

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

Change #1181708 merged by jenkins-bot:

[mediawiki/extensions/CheckUser@master] ipreveal: Remove expired IDs from responses of the batch endpoint

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

Change #1175546 merged by jenkins-bot:

[mediawiki/extensions/CheckUser@master] ipreveal: Show a different error message when data has expired

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

@hector.arroyo:
I am noticing that for any special pages with more than one "Show IP" button for the same expired temporary account, when the user selects one of the "Show IP" buttons it will display no longer available for the "Show IP" button that was selected, but the remaining "Show IP" buttons will display unavailable.

image.png (1,212×210 px, 65 KB)
image.png (430×826 px, 227 KB)
image.png (877×490 px, 140 KB)


However, if I were to then reload the page then it will display the remaining "Show IP" buttons as no longer available.

image.png (1,391×604 px, 123 KB)
image.png (516×827 px, 227 KB)

Is this the expected behavior for this new code, or should the user not have to reload the page to get the new verbiage to show for the remaining "Show IP" buttons?

I am noticing that for any special pages with more than one "Show IP" button for the same expired temporary account, when the user selects one of the "Show IP" buttons it will display no longer available for the "Show IP" button that was selected, but the remaining "Show IP" buttons will display unavailable.
However, if I were to then reload the page then it will display the remaining "Show IP" buttons as no longer available.

Is this the expected behavior for this new code, or should the user not have to reload the page to get the new verbiage to show for the remaining "Show IP" buttons?

That is not the expected behavior. I'll try to check why this is happening during the day.

On Friday, I was able to reproduce the problem locally: When I reveal the IPs for a temp account whose data is expired, only one of the occurrences is shown as "no longer available" (i.e. expired), but reloading the page then shows both as expired.

I'm moving this task back to "In Progress" while I try to find the cause for that.

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

[mediawiki/extensions/CheckUser@master] ipreveal: Show missing IPs as unavailable in ipReveal.js

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

Change #1192129 merged by jenkins-bot:

[mediawiki/extensions/CheckUser@master] ipreveal: Show missing IPs as unavailable in ipReveal.js

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

@hector.arroyo:
I am noticing that for any special pages with more than one "Show IP" button for the same expired temporary account, when the user selects one of the "Show IP" buttons it will display no longer available for the "Show IP" button that was selected, but the remaining "Show IP" buttons will display unavailable.

image.png (1,212×210 px, 65 KB)
image.png (430×826 px, 227 KB)
image.png (877×490 px, 140 KB)


However, if I were to then reload the page then it will display the remaining "Show IP" buttons as no longer available.

image.png (1,391×604 px, 123 KB)
image.png (516×827 px, 227 KB)

Is this the expected behavior for this new code, or should the user not have to reload the page to get the new verbiage to show for the remaining "Show IP" buttons?

https://gerrit.wikimedia.org/r/c/mediawiki/extensions/CheckUser/+/1192129 was merged yesterday, which should fix this issue.

Moving this task back to QA.

Great work on the fix, @hector.arroyo:

New Code Changes have been implemented and verified (Per the Acceptance Criteria)...

QA was completed for this ticket using LocalHost: Mediawiki 1.45.0-alpha (0713c73)...

Testing was performed on various: Skins, Desktop View/MobileView, Chrome/Edge/Firefox/Safari, Windows/Mac/Android/iOS, RTL languages.