Page MenuHomePhabricator

Remove modifications of wgCheckUserLogAdditionalRights in code outside CheckUser
Closed, ResolvedPublic1 Estimated Story Points

Description

To achieve read new for T324907: Create separate tables for log events in CheckUser, the CheckUser tables now store log events in the structured log_params format along with a log_action and log_type. This means that the action text is generated on the fly when showing results of a check.

When reading old, the action text was generated at insert time. This meant that to allow log entries to be shown that have an entry in wgLogRestrictions CheckUser needed to in a newExtraneousContext give temporary user rights such that the CheckUser code could save the actiontext to the database. Extensions that were sending log entries would add the rights to wgCheckUserLogAdditionalRights such that CheckUser could save the actiontext reliably.

The difference means that the config wgCheckUserLogAdditionalRights should no longer be needed, as the action text is generated on view of the log entry and also in a way that uses the rights of the viewing user.

As such, this config should be removed from code in places other than CheckUser in preparation for it's eventual removal in the parent task T366546.

Acceptance criteria
  • Remove modifications or uses of wgCheckUserLogAdditionalRights in all code other than in CheckUser

Event Timeline

Dreamy_Jazz renamed this task from How does wgCheckUserLogAdditionalRights affect read new for event table migration to Remove wgCheckUserLogAdditionalRights.Apr 11 2024, 2:24 PM
Dreamy_Jazz updated the task description. (Show Details)

Change #1050424 had a related patch set uploaded (by Dreamy Jazz; author: Dreamy Jazz):

[operations/mediawiki-config@master] Remove modifications of wgCheckUserLogAdditionalRights

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

Change #1050421 had a related patch set uploaded (by Dreamy Jazz; author: Dreamy Jazz):

[mediawiki/extensions/AbuseFilter@master] Remove modification of wgCheckUserLogAdditionalRights

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

Dreamy_Jazz renamed this task from Remove wgCheckUserLogAdditionalRights to Remove uses of wgCheckUserLogAdditionalRights.Jun 27 2024, 4:44 PM
Dreamy_Jazz updated the task description. (Show Details)
Dreamy_Jazz renamed this task from Remove uses of wgCheckUserLogAdditionalRights to Remove modifications of wgCheckUserLogAdditionalRights in code outside CheckUser.Jun 27 2024, 4:46 PM
Dreamy_Jazz set the point value for this task to 1.Jun 28 2024, 9:39 AM

Change #1050421 merged by jenkins-bot:

[mediawiki/extensions/AbuseFilter@master] Remove modification of wgCheckUserLogAdditionalRights

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

Change #1050424 merged by jenkins-bot:

[operations/mediawiki-config@master] Remove modifications of wgCheckUserLogAdditionalRights

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

Mentioned in SAL (#wikimedia-operations) [2024-07-04T20:05:33Z] <jdrewniak@deploy1002> Started scap sync-world: Backport for [[gerrit:1050671|[July 4th] Reduce list of exclusions for dark mode (1.43.0-wmf.12)]], [[gerrit:1050424|Remove modifications of wgCheckUserLogAdditionalRights (T346022)]], [[gerrit:1052158|Add editcontentmodel to interface-admin for French Wikipedia (T369113)]]

Mentioned in SAL (#wikimedia-operations) [2024-07-04T20:08:52Z] <jdrewniak@deploy1002> jdlrobson, nmw03, jdrewniak, dreamyjazz: Backport for [[gerrit:1050671|[July 4th] Reduce list of exclusions for dark mode (1.43.0-wmf.12)]], [[gerrit:1050424|Remove modifications of wgCheckUserLogAdditionalRights (T346022)]], [[gerrit:1052158|Add editcontentmodel to interface-admin for French Wikipedia (T369113)]] synced to the testservers (https://wikitech.wikimedia.org/wiki/Mwdebug)

Mentioned in SAL (#wikimedia-operations) [2024-07-04T20:17:48Z] <jdrewniak@deploy1002> Finished scap: Backport for [[gerrit:1050671|[July 4th] Reduce list of exclusions for dark mode (1.43.0-wmf.12)]], [[gerrit:1050424|Remove modifications of wgCheckUserLogAdditionalRights (T346022)]], [[gerrit:1052158|Add editcontentmodel to interface-admin for French Wikipedia (T369113)]] (duration: 12m 14s)

kostajh updated the task description. (Show Details)