Page MenuHomePhabricator

Renaming a user doubles their edit count according to CentralAuthUser::getGlobalEditCount() / global_edit_count.gec_count field
Closed, ResolvedPublic

Description

User HotMess received the Wikipedia Library notification telling them they were eligible to access The Wikipedia Library, but they don't actually have enough edits. At the time of writing (they contacted us 10 hours ago), CentralAuth reports a global edit count of 475.

We shouldn't be sending notifications to users unless we can be confident that when they log in to the platform they'll be able to do so successfully.

Related Objects

Event Timeline

There are a very large number of changes, so older changes are hidden. Show Older Changes

Change #1175511 merged by jenkins-bot:

[mediawiki/extensions/CentralAuth@wmf/1.45.0-wmf.12] Clear edit count when unattaching local users for rename

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

Mentioned in SAL (#wikimedia-operations) [2025-08-04T20:55:37Z] <cjming@deploy1003> Started scap sync-world: Backport for [[gerrit:1175511|Clear edit count when unattaching local users for rename (T313900)]], [[gerrit:1175512|fixStuckGlobalRename: Fix using actor_id from the wrong wiki (T398177)]], [[gerrit:1175574|SessionManager: Add $sessionWriteReason to shutdown and when saves are triggered from the destructor (T400249)]]

Mentioned in SAL (#wikimedia-operations) [2025-08-04T20:57:14Z] <cjming@deploy1003> matmarex, cjming: Backport for [[gerrit:1175511|Clear edit count when unattaching local users for rename (T313900)]], [[gerrit:1175512|fixStuckGlobalRename: Fix using actor_id from the wrong wiki (T398177)]], [[gerrit:1175574|SessionManager: Add $sessionWriteReason to shutdown and when saves are triggered from the destructor (T400249)]] synced to the testservers (see https://wikitech.wikimedia.org/w

Mentioned in SAL (#wikimedia-operations) [2025-08-04T21:03:13Z] <cjming@deploy1003> Finished scap sync-world: Backport for [[gerrit:1175511|Clear edit count when unattaching local users for rename (T313900)]], [[gerrit:1175512|fixStuckGlobalRename: Fix using actor_id from the wrong wiki (T398177)]], [[gerrit:1175574|SessionManager: Add $sessionWriteReason to shutdown and when saves are triggered from the destructor (T400249)]] (duration: 07m 36s)

This should be fixed for any accounts renamed from now on. Next step is to write and run a script to recalculate the edit count for previously renamed accounts.

Change #1176310 had a related patch set uploaded (by Bartosz Dziewoński; author: Bartosz Dziewoński):

[mediawiki/extensions/CentralAuth@master] Show cached global edit counts in Special:CentralAuth and API

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

Change #1176311 had a related patch set uploaded (by Bartosz Dziewoński; author: Bartosz Dziewoński):

[mediawiki/extensions/CentralAuth@master] Add maint script to fix global edit count of renamed users

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

Dry run on the beta cluster:

1matmarex@deployment-mwmaint03:~$ mwscript CentralAuth:FixRenamedUserGlobalEditCount --wiki=metawiki
2Edit count already correct for 'RenameMe01'
3Edit count already correct for 'RenameMe02'
4Edit count already correct for 'RenameMe01'
5Renamed user 'RenameMe00' not found (maybe renamed again)
6Renamed user 'Wassup' not found (maybe renamed again)
7Edit count already correct for 'RenameUserTest 01'
8Renamed user 'Ajrtest' not found (maybe renamed again)
9Edit count already correct for 'Ajraddatz'
10Edit count already correct for 'MelosTest'
11Edit count already correct for 'SUL rename test (bd808)'
12Edit count already correct for 'Trijnwagon'
13Edit count already correct for 'ShanmugamTesting'
14Renamed user 'ShanmugamTest' not found (maybe renamed again)
15Edit count already correct for 'ShanmugamTesting'
16Edit count already correct for 'Hydriz-Test'
17Renamed user 'RenamedAccount' not found (maybe renamed again)
18Edit count already correct for 'Krenair-Renamed'
19Renamed user 'TestAccount2' not found (maybe renamed again)
20Edit count already correct for 'Abandoned account aosteuahsh'
21Renamed user 'ET9-test' not found (maybe renamed again)
22Edit count already correct for 'ET9'
23Edit count already correct for 'Kizule'
24Edit count already correct for 'Patrik L.'
25Edit count already correct for 'DutchTina'
26Edit count already correct for 'Majavah renamed test 20210822'
27Would correct edit count for 'TheresNoTime': from 256 to 244
28Would correct edit count for 'EpicPupper (usurped)': from 10 to 5
29Edit count already correct for 'EpicPupper'
30Renamed user 'Tobiastesting3' not found (maybe renamed again)
31Edit count already correct for 'Tobiasdifferent3'
32Edit count already correct for 'Tobiasnewname'
33Edit count already correct for 'Tobiasfirst'
34Would correct edit count for 'Zabe (test 12)': from 16 to 8
35Edit count already correct for 'Daimona test 2'
36Would correct edit count for 'Disrepectful-name-test2': from 2 to 1
37Edit count already correct for 'SeddonRename1'
38Would correct edit count for 'Riaz': from 20 to 10
39Edit count already correct for 'Vanished user 4470eb7b8e79298ce3b2a2b9017a7bc8'
40Would correct edit count for 'Vanished user d9870bab49da527c65500a8373523e83': from 2 to 1
41Edit count already correct for 'Vanished user c4fe28f36617334dd8e6dfdee7c0b3ab'
42Edit count already correct for 'Vanished user b8cef20c53c48fa513c433f3115d6b6f'
43Edit count already correct for 'Vanished user ba4ef68396178ed29d37c15f8a734daf'
44Would correct edit count for 'Vanished user d722e8e3d788ae3321ead91ce00cf91b': from 2 to 1
45Edit count already correct for 'Vanished user 37682ecb7400289504644785dbe50816'
46Edit count already correct for 'Vanished user bf5b7b899f512a6ae0293b445b7683dc'
47Would correct edit count for 'Vanished user dc263540ef5fe584a839649067f7327d': from 2 to 1
48Edit count already correct for 'Vanished user 26 1234'
49Edit count already correct for 'Vanished user 000111222333444555'
50Would correct edit count for 'Vanished user 00011122233344455555': from 2 to 1
51Edit count already correct for 'Vanished user 9f427f308d9c3dbdcf3b6989008aeaec'
52Edit count already correct for 'Drwpb10Changed'
53Edit count already correct for 'Renamed user 90fc40d5282982cf22ca0dd20f38295b'
54Edit count already correct for 'Renamed user d6ec487615c2eb32700f80cb946b9e6f'
55Edit count already correct for 'Renamed user 95554e91bf91bd0b1e62302230783fb2'
56Edit count already correct for 'Test 876tvhjj'
57Would correct edit count for 'LTA-595850459830465': from 4 to 2
58Would correct edit count for 'Renamed user 38adce82008b105e77986cb5d70649bc': from 232 to 116
59Would correct edit count for 'LTA-106351750708556': from 12 to 6
60Would correct edit count for 'Hide on Rosé': from 183 to 181
61Dry run done, would correct 13 edit counts

Change #1176311 merged by jenkins-bot:

[mediawiki/extensions/CentralAuth@master] Add maint script to fix global edit count of renamed users

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

Executed on the beta cluster:

1matmarex@deployment-mwmaint03:~$ mwscript CentralAuth:FixRenamedUserGlobalEditCount --wiki=metawiki --fix
2Edit count already correct for 'RenameMe01'
3Edit count already correct for 'RenameMe02'
4Edit count already correct for 'RenameMe01'
5Renamed user 'RenameMe00' not found (maybe renamed again)
6Renamed user 'Wassup' not found (maybe renamed again)
7Edit count already correct for 'RenameUserTest 01'
8Renamed user 'Ajrtest' not found (maybe renamed again)
9Edit count already correct for 'Ajraddatz'
10Edit count already correct for 'MelosTest'
11Edit count already correct for 'SUL rename test (bd808)'
12Edit count already correct for 'Trijnwagon'
13Edit count already correct for 'ShanmugamTesting'
14Renamed user 'ShanmugamTest' not found (maybe renamed again)
15Edit count already correct for 'ShanmugamTesting'
16Edit count already correct for 'Hydriz-Test'
17Renamed user 'RenamedAccount' not found (maybe renamed again)
18Edit count already correct for 'Krenair-Renamed'
19Renamed user 'TestAccount2' not found (maybe renamed again)
20Edit count already correct for 'Abandoned account aosteuahsh'
21Renamed user 'ET9-test' not found (maybe renamed again)
22Edit count already correct for 'ET9'
23Edit count already correct for 'Kizule'
24Edit count already correct for 'Patrik L.'
25Edit count already correct for 'DutchTina'
26Edit count already correct for 'Majavah renamed test 20210822'
27Corrected edit count for 'TheresNoTime': from 256 to 244
28Corrected edit count for 'EpicPupper (usurped)': from 10 to 5
29Edit count already correct for 'EpicPupper'
30Renamed user 'Tobiastesting3' not found (maybe renamed again)
31Edit count already correct for 'Tobiasdifferent3'
32Edit count already correct for 'Tobiasnewname'
33Edit count already correct for 'Tobiasfirst'
34Corrected edit count for 'Zabe (test 12)': from 16 to 8
35Edit count already correct for 'Daimona test 2'
36Corrected edit count for 'Disrepectful-name-test2': from 2 to 1
37Edit count already correct for 'SeddonRename1'
38Corrected edit count for 'Riaz': from 20 to 10
39Edit count already correct for 'Vanished user 4470eb7b8e79298ce3b2a2b9017a7bc8'
40Corrected edit count for 'Vanished user d9870bab49da527c65500a8373523e83': from 2 to 1
41Edit count already correct for 'Vanished user c4fe28f36617334dd8e6dfdee7c0b3ab'
42Edit count already correct for 'Vanished user b8cef20c53c48fa513c433f3115d6b6f'
43Edit count already correct for 'Vanished user ba4ef68396178ed29d37c15f8a734daf'
44Corrected edit count for 'Vanished user d722e8e3d788ae3321ead91ce00cf91b': from 2 to 1
45Edit count already correct for 'Vanished user 37682ecb7400289504644785dbe50816'
46Edit count already correct for 'Vanished user bf5b7b899f512a6ae0293b445b7683dc'
47Corrected edit count for 'Vanished user dc263540ef5fe584a839649067f7327d': from 2 to 1
48Edit count already correct for 'Vanished user 26 1234'
49Edit count already correct for 'Vanished user 000111222333444555'
50Corrected edit count for 'Vanished user 00011122233344455555': from 2 to 1
51Edit count already correct for 'Vanished user 9f427f308d9c3dbdcf3b6989008aeaec'
52Edit count already correct for 'Drwpb10Changed'
53Edit count already correct for 'Renamed user 90fc40d5282982cf22ca0dd20f38295b'
54Edit count already correct for 'Renamed user d6ec487615c2eb32700f80cb946b9e6f'
55Edit count already correct for 'Renamed user 95554e91bf91bd0b1e62302230783fb2'
56Edit count already correct for 'Test 876tvhjj'
57Corrected edit count for 'LTA-595850459830465': from 4 to 2
58Corrected edit count for 'Renamed user 38adce82008b105e77986cb5d70649bc': from 232 to 116
59Corrected edit count for 'LTA-106351750708556': from 12 to 6
60Corrected edit count for 'Hide on Rosé': from 183 to 181
61Done, corrected 13 edit counts

Change #1181788 had a related patch set uploaded (by Bartosz Dziewoński; author: Bartosz Dziewoński):

[mediawiki/extensions/CentralAuth@wmf/1.45.0-wmf.15] Add maint script to fix global edit count of renamed users

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

Change #1176310 merged by jenkins-bot:

[mediawiki/extensions/CentralAuth@master] Show cached global edit counts in Special:CentralAuth and API

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

Change #1181788 merged by jenkins-bot:

[mediawiki/extensions/CentralAuth@wmf/1.45.0-wmf.15] Add maint script to fix global edit count of renamed users

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

Mentioned in SAL (#wikimedia-operations) [2025-08-26T13:20:42Z] <lucaswerkmeister-wmde@deploy1003> Started scap sync-world: Backport for [[gerrit:1181782|PHPSessionHandler: Better handle objects stored in the session (T402602)]], [[gerrit:1181788|Add maint script to fix global edit count of renamed users (T313900)]], [[gerrit:1181789|Add maint script to fix wrong actors in local log entries for global renames (T398177)]]

Mentioned in SAL (#wikimedia-operations) [2025-08-26T13:26:59Z] <lucaswerkmeister-wmde@deploy1003> matmarex, lucaswerkmeister-wmde: Backport for [[gerrit:1181782|PHPSessionHandler: Better handle objects stored in the session (T402602)]], [[gerrit:1181788|Add maint script to fix global edit count of renamed users (T313900)]], [[gerrit:1181789|Add maint script to fix wrong actors in local log entries for global renames (T398177)]] synced to the testservers (see https://wikitech.wikim

Mentioned in SAL (#wikimedia-operations) [2025-08-26T13:33:37Z] <lucaswerkmeister-wmde@deploy1003> Finished scap sync-world: Backport for [[gerrit:1181782|PHPSessionHandler: Better handle objects stored in the session (T402602)]], [[gerrit:1181788|Add maint script to fix global edit count of renamed users (T313900)]], [[gerrit:1181789|Add maint script to fix wrong actors in local log entries for global renames (T398177)]] (duration: 12m 54s)

Mentioned in SAL (#wikimedia-operations) [2025-08-26T13:35:51Z] <lucaswerkmeister-wmde@deploy1003> mwscript-k8s job started: CentralAuth:FixRenamedUserGlobalEditCount metawiki # T313900 (dry run)

Mentioned in SAL (#wikimedia-operations) [2025-08-26T13:35:51Z] <lucaswerkmeister-wmde@deploy1003> mwscript-k8s job started: CentralAuth:FixRenamedUserGlobalEditCount metawiki # T313900 (dry run)

The script ran for ca. 55 minutes before dying with an out-of-memory error (@Clement_Goubert has more details). The output so far is here (warning, long): P81771

$ grep -cF 'Would correct edit count' T313900.dry
225
$ grep -cF 'Edit count already correct' T313900.dry
47526
$ grep -cF 'not found (maybe renamed again)' T313900.dry
3030
cgoubert@deploy1003$ kubectl get job -l script=FixRenamedUserGlobalEditCount
NAME                       COMPLETIONS   DURATION   AGE
mw-script.eqiad.ieyltg2e   0/1           60m        60m
cgoubert@deploy1003$ kubectl describe pod mw-script.eqiad.ieyltg2e-6m97x | grep Reason
      Reason:       OOMKilled

image.png (533×1 px, 56 KB)
Grafana link

I don't know why it OOMs. I haven't found any smoking guns in CentralAuth code, and I couldn't reproduce the memory leak locally.

There are only 150,000 or so global rename log entries, and the script made it to around 50,000 before it died, so let's just run it in 3-4 batches. I'll add some parameters to allow doing that. We should have an easier way to do this kind of thing without handling it manually…

Change #1182234 had a related patch set uploaded (by Bartosz Dziewoński; author: Bartosz Dziewoński):

[mediawiki/extensions/CentralAuth@master] FixRenamedUserGlobalEditCount: Add --since and --until parameters

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

Change #1182235 had a related patch set uploaded (by Bartosz Dziewoński; author: Bartosz Dziewoński):

[mediawiki/extensions/CentralAuth@master] FixRenamedUserGlobalEditCount: Improve logs

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

The bug can't affect renames performed before 10 March 2022, since we were not tracking the global edit count before then (https://gerrit.wikimedia.org/r/q/I48c59779deae32d3d358cd2d5f9019853c0d1f61). Although there are two affected users in the partial log that ends somewhere in 2019, that's because both of them have been renamed again after that date.

We've done between 10,000 and 20,000 renames per year (select left(log_timestamp, 4), count(*) from logging where log_type='gblrename' and log_action='rename' group by 1;) – that's honestly a lot more than I expected – which nevertheless should be comfortably less than the point where the mysterious memory leak leads to a crash. So, we should run four batches like this, to keep things simple:

--since 20220310000000 --until 20230101000000
--since 20230101000000 --until 20240101000000
--since 20240101000000 --until 20250101000000
--since 20250101000000

Change #1182234 merged by jenkins-bot:

[mediawiki/extensions/CentralAuth@master] FixRenamedUserGlobalEditCount: Add --since and --until parameters

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

Change #1182235 merged by jenkins-bot:

[mediawiki/extensions/CentralAuth@master] FixRenamedUserGlobalEditCount: Improve script output

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

Change #1182636 had a related patch set uploaded (by Bartosz Dziewoński; author: Bartosz Dziewoński):

[mediawiki/extensions/CentralAuth@wmf/1.45.0-wmf.15] FixRenamedUserGlobalEditCount: Add --since and --until parameters

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

Change #1182637 had a related patch set uploaded (by Bartosz Dziewoński; author: Bartosz Dziewoński):

[mediawiki/extensions/CentralAuth@wmf/1.45.0-wmf.15] FixRenamedUserGlobalEditCount: Improve script output

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

Change #1182640 had a related patch set uploaded (by Bartosz Dziewoński; author: Bartosz Dziewoński):

[mediawiki/extensions/CentralAuth@wmf/1.45.0-wmf.16] FixRenamedUserGlobalEditCount: Add --since and --until parameters

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

Change #1182642 had a related patch set uploaded (by Bartosz Dziewoński; author: Bartosz Dziewoński):

[mediawiki/extensions/CentralAuth@wmf/1.45.0-wmf.16] FixRenamedUserGlobalEditCount: Improve script output

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

Change #1182636 merged by jenkins-bot:

[mediawiki/extensions/CentralAuth@wmf/1.45.0-wmf.15] FixRenamedUserGlobalEditCount: Add --since and --until parameters

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

Change #1182637 merged by jenkins-bot:

[mediawiki/extensions/CentralAuth@wmf/1.45.0-wmf.15] FixRenamedUserGlobalEditCount: Improve script output

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

Change #1182640 merged by jenkins-bot:

[mediawiki/extensions/CentralAuth@wmf/1.45.0-wmf.16] FixRenamedUserGlobalEditCount: Add --since and --until parameters

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

Change #1182642 merged by jenkins-bot:

[mediawiki/extensions/CentralAuth@wmf/1.45.0-wmf.16] FixRenamedUserGlobalEditCount: Improve script output

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

Mentioned in SAL (#wikimedia-operations) [2025-08-27T20:37:04Z] <bd808@deploy1003> Started scap sync-world: Backport for [[gerrit:1182636|FixRenamedUserGlobalEditCount: Add --since and --until parameters (T313900)]], [[gerrit:1182637|FixRenamedUserGlobalEditCount: Improve script output (T313900)]], [[gerrit:1182638|FixRenameUserLocalLogs: Old username may not be valid (T398177)]], [[gerrit:1182639|FixRenameUserLocalLogs: Improve finding local log entries (T398177)]], [[gerrit:11826

Mentioned in SAL (#wikimedia-operations) [2025-08-27T20:43:11Z] <bd808@deploy1003> matmarex, bd808: Backport for [[gerrit:1182636|FixRenamedUserGlobalEditCount: Add --since and --until parameters (T313900)]], [[gerrit:1182637|FixRenamedUserGlobalEditCount: Improve script output (T313900)]], [[gerrit:1182638|FixRenameUserLocalLogs: Old username may not be valid (T398177)]], [[gerrit:1182639|FixRenameUserLocalLogs: Improve finding local log entries (T398177)]], [[gerrit:1182640|FixRe

Mentioned in SAL (#wikimedia-operations) [2025-08-27T20:50:03Z] <bd808@deploy1003> Finished scap sync-world: Backport for [[gerrit:1182636|FixRenamedUserGlobalEditCount: Add --since and --until parameters (T313900)]], [[gerrit:1182637|FixRenamedUserGlobalEditCount: Improve script output (T313900)]], [[gerrit:1182638|FixRenameUserLocalLogs: Old username may not be valid (T398177)]], [[gerrit:1182639|FixRenameUserLocalLogs: Improve finding local log entries (T398177)]], [[gerrit:1182

Mentioned in SAL (#wikimedia-operations) [2025-08-28T13:21:41Z] <lucaswerkmeister-wmde@deploy1003> mwscript-k8s job started: CentralAuth:FixRenamedUserGlobalEditCount metawiki --since=20220310000000 --until=20230101000000 # T313900 (dry run)

Mentioned in SAL (#wikimedia-operations) [2025-08-28T13:33:46Z] <lucaswerkmeister-wmde@deploy1003> mwscript-k8s job started: CentralAuth:FixRenamedUserGlobalEditCount metawiki --since=20230101000000 --until=20240101000000 # T313900 (dry run)

Mentioned in SAL (#wikimedia-operations) [2025-08-28T13:54:14Z] <lucaswerkmeister-wmde@deploy1003> mwscript-k8s job started: CentralAuth:FixRenamedUserGlobalEditCount metawiki --since=20240101000000 --until=20250101000000 # T313900 (dry run)

Mentioned in SAL (#wikimedia-operations) [2025-08-28T14:14:22Z] <lucaswerkmeister-wmde@deploy1003> mwscript-k8s job started: CentralAuth:FixRenamedUserGlobalEditCount metawiki --since=20250101000000 # T313900 (dry run)

The bug can't affect renames performed before 10 March 2022, since we were not tracking the global edit count before then (https://gerrit.wikimedia.org/r/q/I48c59779deae32d3d358cd2d5f9019853c0d1f61). Although there are two affected users in the partial log that ends somewhere in 2019, that's because both of them have been renamed again after that date.

We've done between 10,000 and 20,000 renames per year (select left(log_timestamp, 4), count(*) from logging where log_type='gblrename' and log_action='rename' group by 1;) – that's honestly a lot more than I expected – which nevertheless should be comfortably less than the point where the mysterious memory leak leads to a crash. So, we should run four batches like this, to keep things simple:

--since 20220310000000 --until 20230101000000
--since 20230101000000 --until 20240101000000
--since 20240101000000 --until 20250101000000
--since 20250101000000

Output of those four batches: P82030, P82031, P82032, P82033.

Change #1182868 had a related patch set uploaded (by Lucas Werkmeister (WMDE); author: Lucas Werkmeister (WMDE)):

[mediawiki/extensions/CentralAuth@master] Add caller to maintenance script SQL queries

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

Change #1182868 merged by jenkins-bot:

[mediawiki/extensions/CentralAuth@master] Add caller to maintenance script SQL queries

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

The outputs look right to me.

  • Of the 42,793 items, in around half of the cases the edit count was (almost) exactly 2 times the correct one, indicating that they were affected by this bug.
  • A few users who have been renamed multiple times have predictably more incorrect numbers (such as Ⓝⓘⓙⓦⓜ, who has been renamed 5 times perhaps due to some bug in another maintenance script, has 6 times the expected number of edits).
  • Users who continued editing after their rename have higher edit counts than they should, but less than double (since only edits before the rename were double-counted).
  • There are a few users where the edit count was less than the correct one (by just a couple of edits). I will try not to think about this, I'm sure we could waste weeks investigating.

As a side note, I didn't realize how common it is for users to be renamed more than once (in ~3.5% of the renames, the "new" username no longer exists). In some cases the user was even renamed back to the original username.

We should run the scripts with --fix next week, which will finally resolve this task.

The new "Sum of local edit counts" message shows up for MusikBot II – an account that was never renamed.

There are a few users where the edit count was less than the correct one (by just a couple of edits). I will try not to think about this, I'm sure we could waste weeks investigating.

Could this be due to edits the user made to user pages of other users who were renamed? That would make sense in the case of MusikBot II, I think.

The new "Sum of local edit counts" message shows up for MusikBot II – an account that was never renamed.

There are a few users where the edit count was less than the correct one (by just a couple of edits). I will try not to think about this, I'm sure we could waste weeks investigating.

Could this be due to edits the user made to user pages of other users who were renamed? That would make sense in the case of MusikBot II, I think.

I don't really see how that specific scenario could happen. I think that for the most part, this happens because bumping of local edit counter and bumping of global edit counter are not in a transaction (because they write to different databases), so if for whatever reason one of them fails and the other succeeds, the numbers will no longer match. But there could be some weirder cases as well.

Change #1183640 had a related patch set uploaded (by D3r1ck01; author: Lucas Werkmeister (WMDE)):

[mediawiki/extensions/CentralAuth@wmf/1.45.0-wmf.16] Add caller to maintenance script SQL queries

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

Change #1183640 merged by jenkins-bot:

[mediawiki/extensions/CentralAuth@wmf/1.45.0-wmf.16] Add caller to maintenance script SQL queries

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

Mentioned in SAL (#wikimedia-operations) [2025-09-01T13:30:39Z] <lucaswerkmeister-wmde@deploy1003> Started scap sync-world: Backport for [[gerrit:1183640|Add caller to maintenance script SQL queries (T313900 T398177 T403387)]], [[gerrit:1183653|FixRenameUserLocalLogs: Batch more queries to speed up the script (T398177)]], [[gerrit:1183654|FixRenameUserLocalLogs: Skip rows where the performer is 'Global rename script' (T398177)]]

Mentioned in SAL (#wikimedia-operations) [2025-09-01T13:36:43Z] <lucaswerkmeister-wmde@deploy1003> lucaswerkmeister-wmde, matmarex, d3r1ck01: Backport for [[gerrit:1183640|Add caller to maintenance script SQL queries (T313900 T398177 T403387)]], [[gerrit:1183653|FixRenameUserLocalLogs: Batch more queries to speed up the script (T398177)]], [[gerrit:1183654|FixRenameUserLocalLogs: Skip rows where the performer is 'Global rename script' (T398177)]] synced to the testservers (see http

Mentioned in SAL (#wikimedia-operations) [2025-09-01T13:42:27Z] <lucaswerkmeister-wmde@deploy1003> Finished scap sync-world: Backport for [[gerrit:1183640|Add caller to maintenance script SQL queries (T313900 T398177 T403387)]], [[gerrit:1183653|FixRenameUserLocalLogs: Batch more queries to speed up the script (T398177)]], [[gerrit:1183654|FixRenameUserLocalLogs: Skip rows where the performer is 'Global rename script' (T398177)]] (duration: 11m 48s)

Mentioned in SAL (#wikimedia-operations) [2025-09-01T13:45:07Z] <lucaswerkmeister-wmde@deploy1003> mwscript-k8s job started: CentralAuth:FixRenamedUserGlobalEditCount metawiki --fix --since=20220310000000 --until=20230101000000 # T313900

Mentioned in SAL (#wikimedia-operations) [2025-09-01T14:02:14Z] <lucaswerkmeister-wmde@deploy1003> mwscript-k8s job started: CentralAuth:FixRenamedUserGlobalEditCount metawiki --fix --since=20230101000000 --until=20240101000000 # T313900

Mentioned in SAL (#wikimedia-operations) [2025-09-01T14:20:49Z] <lucaswerkmeister-wmde@deploy1003> mwscript-k8s job started: CentralAuth:FixRenamedUserGlobalEditCount metawiki --fix --since=20240101000000 --until=20250101000000 # T313900

Mentioned in SAL (#wikimedia-operations) [2025-09-01T14:38:27Z] <lucaswerkmeister-wmde@deploy1003> mwscript-k8s job started: CentralAuth:FixRenamedUserGlobalEditCount metawiki --fix --since=20250101000000 # T313900

Output of the four script runs to fix the edit counts: P82328, P82329, P82330, P82331

We should run the scripts with --fix next week, which will finally resolve this task.

Given that the script has now been run (thanks @Lucas_Werkmeister_WMDE !), can we resolve this?