Page MenuHomePhabricator

[SPIKE] Test Automoderator with Indonesian Wikipedia's FlaggedRevs configuration [8HRS]
Open, MediumPublicSpike

Description

Our prototype of Automoderator works well in a default MediaWiki environment. One potential complication is that a few dozen wikis use the MediaWiki-extensions-FlaggedRevs extension to hold edits for review by designated patrollers. We need to understand how Automoderator currently interfaces with Flagged Revisions so that we can make any changes necessary to have it operate smoothly on those wikis.

This question primarily concerns the technical side of this - we may also need to consult with patrollers to understand their expectations around how Automoderator would behave.

Questions might include:

  • Is Automoderator able to revert edits when Flagged Revisions is enabled?
  • Are system account edits (i.e. Automoderator) also flagged for review by patrollers, or are they treated as trusted edits?

Event Timeline

Restricted Application changed the subtype of this task from "Task" to "Spike". · View Herald TranscriptFeb 7 2024, 6:30 PM
Restricted Application added a subscriber: Aklapper. · View Herald Transcript
  • Is Automoderator able to revert edits when Flagged Revisions is enabled?

The purpose of FlaggedRevs is to hide edits rather than preventing them, so it shouldn’t prevent PageUpdater from doing edits.

  • Are system account edits (i.e. Automoderator) also flagged for review by patrollers, or are they treated as trusted edits?

FlaggedRevs knows nothing about system accounts, only user rights. An edit is reviewed among others if

  • the user has autoreview right, and
  • either the edit is a revert to the stable revision (the SHA1 hashes match), or auto-review is enabled in config (it’s enabled on all WMF wikis) and the previous version is reviewed.

The above conditions mean that if the Automoderator account has the autoreview right (I assume system accounts can also have user rights?), the patrollers don’t get extra work – if the page had no unreviewed edits, or the only unreviewed edit was the one that has just been reverted, the revert is auto-reviewed. If there were more unreviewed edits, the page is not reviewed (unless those unreviewed edits happened to be back-and-forth reverts by non-autoreviewer users) – and neither should it be, since the previous edits still need manual review. These unreviewed edits don’t add to the backlog, as the page has already been in the backlog due to the previous unreviewed edits.

However, the logic (rEFLR includes/backend/FlaggedRevsHooks.php:394-539 (at 8e6abc00e9bb)) accesses the global $wgRequest object several times, which is a bit scary, as the request is the one that made the to-be-reverted edit, not the revert edit.

Thanks for all this great information @Tacsipacsi!

It seems like, at least on de.wiki, bots have the autoreview flag (https://de.wikipedia.org/wiki/Spezial:Gruppenrechte) so it might make sense for system accounts to have this too, but perhaps this would need to be something discussed with each FlaggedRevs community.

It seems like, at least on de.wiki, bots have the autoreview flag

Yes, on all wikis (T15989).

A note for our pilot wiki (idwiki): It currently has this in config:

$wgGroupPermissions['sysop']['stablesettings'] = true;
$wgFlaggedRevsRestrictionLevels = [ 'autoconfirmed', 'autoreview', 'sysop' ];

A note for our pilot wiki (idwiki): It currently has this in config:

$wgGroupPermissions['sysop']['stablesettings'] = true;
$wgFlaggedRevsRestrictionLevels = [ 'autoconfirmed', 'autoreview', 'sysop' ];

I believe you may also need to look for wgFlaggedRevsProtection, since that is the mode that id.wiki uses (true).

Samwalton9-WMF renamed this task from Does Automoderator work when Flagged Revisions is enabled? to Test Automoderator with Indonesian Wikipedia's FlaggedRevs configuration.Mon, Apr 8, 1:33 PM
Samwalton9-WMF moved this task from Inbox to To be estimated on the Moderator-Tools-Team board.
jsn.sherman renamed this task from Test Automoderator with Indonesian Wikipedia's FlaggedRevs configuration to [SPIKE] Test Automoderator with Indonesian Wikipedia's FlaggedRevs configuration [8HRS].Tue, Apr 16, 3:30 PM
jsn.sherman moved this task from To be estimated to Up next on the Moderator-Tools-Team board.
Samwalton9-WMF moved this task from Up next to Kanban on the Moderator-Tools-Team board.