Page MenuHomePhabricator

Ensure UserGroupManager::addUserToGroup is not called on temporary users from Echo extension
Closed, ResolvedPublic

Description

Following T340470, Ensure that UserGroupManager::addUserToGroup is not called on temporary users in Echo extension
Link to code search where calls are made can be found here

Event Timeline

The call here is made by the script that is used to generate sample notifications
Class: documentation: GenerateSampleNotifications
A maintenance script that generates sample notifications for testing purposes.

When running the script it also specifis that it should only be run on test wikis see code below and here

$this->output( "ONLY RUN ON TEST WIKIS\n" );
}

And finally when running the script with the command below

php maintenance/generateSampleNotifications.php --agent "*Unregistered 13" --user "*Unregistered 13" -o Admin
}

It Errors out with the following:

UserGroupManager::addUserToGroup() cannot be called on a temporary user

This is the result of this patch

Given all this I think this can be marked as resolved.

It Errors out with the following:

UserGroupManager::addUserToGroup() cannot be called on a temporary user

This is the result of this patch

This patch has been reverted but will generate another error soon.
One way or another, the error will come up as planned.

Urbanecm_WMF moved this task from Triaged to Inbox on the Growth-Team board.