Error
- mwversion: 1.44.0-wmf.19
- reqId: 8b961d04-c737-441c-8558-6edf6f1a3e2d
- Find reqId in Logstash
[{reqId}] {exception_url} RuntimeException: Can\'t reblock a user with multiple blocks already present. Update calling code for multiblocks, providing a specific block to update.Impact
- Some users have two block_target rows. These users cannot be unblocked.
Notes
See also: T387723: Special:InvestigateBlock: RuntimeException: Can't reblock a user with multiple blocks already present., T387730: Special:MassGlobalBlock: RuntimeException: Can't reblock a user with multiple blocks already present
Derived Requirement
Ensure that Special:Block properly handles users/IPs with multiple existing blocks by:
- Preventing the RuntimeException: Can't reblock a user with multiple blocks already present.
- Allowing unblock operations to function correctly even when multiple block_target rows exist.
- Updating the calling code for multiblocks to provide a specific block to update, instead of failing with an exception.
Test Steps
Test Case 1: Verify that Special:Block does not throw a RuntimeException when reblocking a user with multiple existing blocks
- Navigate to Special:Block on a wiki where multiblocks are enabled.
- Enter a target user/IP and apply a first block.
- Apply a second block on the same user/IP.
- Attempt to reblock the same user/IP with a different expiration or block reason.
- Turn off multiblocks and Codex Special:Block
- Go to Special:Block again and try to reblock the same user
- ✅ ❓❌⬜AC1: Confirm that the system does not throw a RuntimeException and does not allow reblocking. You should see an error that you cannot reblock
- ✅❓❌⬜ AC2: Confirm that the existing blocks are correctly updated or preserved without corruption.
QA Results - Local
| AC | Status | Details |
|---|---|---|
| 1 | ✅ | T388743#10654262 |
| 2 | ✅ | T388743#10654262 |
