Page MenuHomePhabricator

AccountVanishRequest locks should always be done on Meta-Wiki
Closed, ResolvedPublic

Description

It's general custom that account locks are always done on Meta-Wiki to keep the logs for them in a consistent place. Most locks by AccountVanishRequests are done there, but there are several entries in https://en.wikipedia.org/wiki/Special:Log?type=globalauth&user=AccountVanishRequests&page=&wpdate=&tagfilter=&wpfilters%5B%5D=newusers&wpFormIdentifier=logeventslist, which shouldn't be done.

Steps to reproduce

  1. Create a new account
  2. Open Special:GlobalVanishRequest on any other wiki than the central wiki (defined as metawiki on beta wikis and WMF wikis) using this new account and fill out the form
  3. Notice that the account vanishing is automatically approved
  4. Log into another account and look at the vanishing logs (in the globalauth log type)
  5. See that the log is not on the central wiki but instead on the wiki where the user requested vanishing

Acceptance criteria

  • Automatically approved account vanishing requests have their log entries stored on the central wiki, defined on WMF wikis as metawiki.

Event Timeline

No. This request is saying that regardless of what wiki you use to request vanishing on, the lock should be logged on Meta-Wiki.

From my local testing it seems like the log entry's destination is currently determined by the wiki that the renamer uses to approve the vanish request regardless of which wiki the request was originally made on by the user.

That's fine, except for auto-approvals where the wiki the rename is approved on is the wiki where it was requested.

Understood! Is there any existing mechanism to insert cross-wiki log entries easily? If not, it looks like CentralAuth handles cross-wiki actions (such as renaming users and moving their pages) by scheduling jobs and maybe a similar approach can be used for inserting the log entries for auto-approved vanishes.

Understood! Is there any existing mechanism to insert cross-wiki log entries easily? If not, it looks like CentralAuth handles cross-wiki actions (such as renaming users and moving their pages) by scheduling jobs and maybe a similar approach can be used for inserting the log entries for auto-approved vanishes.

There is no method currently to create a log entry on any wiki than the current wiki. It is possible to use a job where the job is executed in the context of a different wiki. Examples are in MediaWiki-extensions-CentralAuth as you note.

Amdrel changed the task status from Open to In Progress.Mar 4 2025, 1:48 AM

Change #1124521 had a related patch set uploaded (by Amdrel; author: Amdrel):

[mediawiki/extensions/CentralAuth@master] Execute automatic vanish requests using a job

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

The patch I just added moves the execution of the automatic vanish to a job which can be configured to execute on Meta-Wiki.

Change #1124521 merged by jenkins-bot:

[mediawiki/extensions/CentralAuth@master] Execute automatic vanish requests using a job

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

Moving to "In Progress" as we still need a config patch to set $wgCentralAuthAutomaticVanishWiki on WMF wikis.

Change #1125497 had a related patch set uploaded (by Amdrel; author: Amdrel):

[operations/mediawiki-config@master] CommonSettings.php: Add $wgCentralAuthAutomaticVanishWiki

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

Change #1125497 merged by jenkins-bot:

[operations/mediawiki-config@master] CommonSettings.php: Add $wgCentralAuthAutomaticVanishWiki

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

Djackson-ctr subscribed.

QA is completed, and the new code has been implemented and is functioning as expected (Automatically approved account vanishing requests will have their log entries stored on the central wiki).

image.png (768×1 px, 47 KB)