When setting up integrations and clicking 'activate', we get the following error. We can setup the integration as assign roles without issues. The error happens when we come to click the 'activate' button.
Internal error. Check exception log for details.
[2020-10-08 09:51:26] main.CRITICAL: Role '48' not found {"exception":"[object] (Zend_Acl_Role_Registry_Exception(code: 0): Role '48' not found at ../vendor/magento/zendframework1/library/Zend/Acl/Role/Registry.php:132)"} []
[2020-10-08 09:51:26] main.CRITICAL: Something went wrong while compiling a list of allowed resources. You can find out more in the exceptions log. {"exception":"[object] (Magento\\Framework\\Exception\\LocalizedException(code: 0): Something went wrong while compiling a list of allowed resources. You can find out more in the exceptions log. at ../vendor/magento/module-authorization/Model/Acl/AclRetriever.php:95)"} []
Hello @ashtreedesign
Seems like either you have migrated your data or deleted any role but the user still exists.
You can change the role id for those users who have role_id = 48
you can directly change in admin users and the specific role which exists.
If still doesn't help, check these table if it has any role_id as 48 and change that role id to your desired role id :
admin_user
authorization_role
authorization_rule
Hope it helps !
Thanks for the reply. The issue there is that there are only two roles in the admin area. ID 1 and ID 44.
so most probably that id is deleted, you can assign 44 or 1 as per you want or you can create a new user role and assign that ID where you are getting 48.
Hope it helps !
That seems to cause another issue. When I create a new role, I get the following when trying to then view it....
Exception #0 (Zend_Acl_Role_Registry_Exception): Role '49' not found
Seems like so many roles are deleted or missing, just change all the id's in database to ID 1 or 44 which doesn't exist and later create specific role and assign to users.
or if you have any backup data, then you can compare these three tables and update your database.
Thanks. So am I editing the entries in authorisation_rule table? Looking in that table, there is a role 48 and 49 visible in the database.
So in the admin table, there are 5 admin account.
ID 1,2,3,5,7
In the authorization_role table
Role ID: 2 - User ID: 0
Role ID: 31 - User ID: 2
Role ID: 36 - User ID: 1
Role ID: 38 - User ID: 35
Role ID: 39 - User ID: 3
Role ID: 41 - User ID: 37
Role ID: 43 - User ID: 5
Role ID: 44 - User ID: 0
Role ID: 46 - User ID: 7
Role ID: 47 - User ID: 38
Role ID: 48 - User ID: 39
Role ID: 49 - User ID: 0
So when logged in as user ID 2, trying to enable an integration, I get "role 48 not found", is that because role 48 isn't assigned to me?
When looking at the integration table in the DB, there doesn't seem to be any mention of role or user.
I have to same error and I don't know how to solve it. Any help please?
This is probably a bit late, but for people that stumble on this problem: we noticed that flushing the cache immediately after creating an integration gets rid of this problem.
So:
- create an integration
- flush all caches
- activate the integration
That solved this problem for us.
It sounds like a bug in Magento, but I haven't tested it on the latest version, so not sure if it's still a bug or not.