Access denied for users after upgrading from Modx 3.0.6 to 3.1.0 using upgrade add-on

Summary

I upgraded using the update add-on from 3.05 to 3.06 without any problem.
Then I tried 3.0.6 to 3.1.0 as I wanted to get step by step to the latest version.
the setup brought up the “priority group” problem. I fixed it in the DB and
restarted setup. told me to remove the .locked directory, which I did.
Then setup run through and showed all green ticks.

but now no user can log in…

Step to reproduce

How to reproduce the issue, including custom code if needed.

Observed behavior

How it behaved after following the steps above. Annotated screenshots here are excellent.

Expected behavior

How it should behave after following the steps above.

Environment

MODX version tagged 3.1.0

What exactly do you mean by “the priority group problem”?
How exactly did you fix it?
Were you able to log in after this change (and before upgrading to MODX 3.1.0)?

What exactly happens when you try to log in? Is there an error message displayed?
Is this also true for sudo users?

[2025-06-21 18:32:39] (ERROR in xPDO\Om\mysql\xPDOManager::addIndex @ /homepages/19/d235031791/htdocs/Tonkoepfe 3.2/twkd/core/vendor/xpdo/xpdo/src/xPDO/Om/mysql/xPDOManager.php : 316) Error adding index authority to MODX\Revolution\modUserGroupRole: Array
(
[0] => 23000
[1] => 1062
[2] => Duplicate entry ‘0’ for key ‘authority’
)
This was a problem reported when upgrading from 3.06 to 3.1.0. using the upgrade add on.
3.0.5 to 3.0.6 went without any warning or error

This

Sudo user I don’t have. Is it enough to set the sudo flag in the user db? Then I could try that out.
And thanks a lot for providing ideas!!!

Yes, this should do the trick.

Maybe you also have to clear the cache (deleting the content of core/cache) or delete existing sessions (data in the database table modx_session with the default settings).

Yes there was a change in the database table. The “authority” of a role has to be unique now.

After changing the “authority” value, you may also have to adjust the ACLs (“Minimum Role” for a policy in the user group) to have the same behaviour as before. It depends on your specific setup.

There is no difference if you do a manual upgrade (and call setup/ manually) or use the UpgradeMODX extra. The extra just simplifies the process (by downloading and unzipping the ZIP-file automatically).

cache I cleared already, ok thanks, will check the sudo and the sessions.
The ACL I can also update directly on the DB?

It’s possible by using the different tables modx_access_... (like e.g. modx_access_context). But it might be easier to log in with a sudo user (if that works) and then change it in the MODX manager (if changes are really necessary).

THANK YOU!, Sudo user worked, I can log in. I understand that I now need to recheck the access rights settings of the users

This topic was automatically closed 2 days after discussion ended and a solution was marked. New replies are no longer allowed. You can open a new topic by clicking the link icon below the original post or solution and selecting “+ New Topic”.