Setting undefined permission "access.settings" is deprecated and will be ignored in a future version

Hey,

I have updated my Kirby instance to the newest avail. version (5.5.2). Since the updates I cannot access the Panel. I always get the following error but cannot find any traces of the access settings inside of my plugins, even with no plugins (pluginfolder renamed to “plugins_old” is is not working and Whoops is also no help :confused:

This is the error:


Whoops \ Exception \ ErrorException (E_USER_DEPRECATED)
Setting undefined permission "access.settings" is deprecated and will be ignored in a future version. Please use https://getkirby.com/docs/reference/plugins/extensions/permissions to register custom permissions.

This is the Stack:

 Whoops\Exception\ErrorException
…/kirby/src/Cms/Helpers.php:83
22
trigger_error
…/kirby/src/Cms/Helpers.php:83
21
Kirby\Cms\Helpers deprecated
…/kirby/src/Cms/Permissions.php:245
20
Kirby\Cms\Permissions normalize
…/kirby/src/Cms/Permissions.php:124
19
Kirby\Cms\Permissions __construct
…/kirby/src/Cms/Role.php:32
18
Kirby\Cms\Role __construct
…/kirby/src/Cms/Role.php:92
17
Kirby\Cms\Role factory
…/kirby/src/Cms/Role.php:160
16
Kirby\Cms\Role load
…/kirby/src/Cms/Roles.php:134
15
Kirby\Cms\Roles load
…/kirby/src/Cms/AppUsers.php:74
14
Kirby\Cms\App roles
…/kirby/src/Cms/User.php:599
13
Kirby\Cms\User role
…/kirby/src/Panel/View.php:144
12
Kirby\Panel\View data
…/kirby/src/Panel/View.php:344
11
Kirby\Panel\View response
…/kirby/src/Panel/Panel.php:289
10
Kirby\Panel\Panel response
…/kirby/src/Panel/Panel.php:344
9
Kirby\Panel\Panel {closure:Kirby\Panel\Panel::router():319}
…/kirby/src/Http/Router.php:120
8
Kirby\Http\Router call
…/kirby/src/Http/Router.php:153
7
Kirby\Http\Router execute
…/kirby/src/Panel/Panel.php:319
6
Kirby\Panel\Panel router
…/kirby/config/routes.php:160
5
Kirby\Http\Route {closure:{closure:<<absolute path>>/kirby/config/routes.php:14}:159}
[internal]:0
4
Closure call
…/kirby/src/Http/Router.php:122
3
Kirby\Http\Router call
…/kirby/src/Cms/App.php:346
2
Kirby\Cms\App call
…/kirby/src/Cms/App.php:1214
1
Kirby\Cms\App render
…/index.php:6
0
require
…/kirby/router.php:21

What can I do?

Thanks for the help ^^

Same here. It worked for me when i turned off debug but it’s strange.

Can confirm this… If I turn of debug it works :confused:
Reinstalling doesn’t solve the problem either. Even if I downgrade to 5.5.1 or 5.5.0 it is not working… very strange…

Okay… It seems that the error mesage is leading in the wrong direction…

After checking the core code it seems that the blueprint parser also uses the function to check if a key is deprecated…

In my installation I have some Roles defined under site/blueprints/users - there is a section defined names access.

In my case it looks like that (e.g):

title: Admin
permissions:
  access:
    panel: true
    site: true
    settings: true
    users: true
  files: true
  languages: true
  pages: true
  site: true
  users: true

There is a key named “settings” that needs to be updated to “system” I suppose.

=> …/kirby/src/Cms/Permissions.php:243 and :24ff
These are the defaults / available keys for access:

	protected array $defaults = [
		'access' => [
			'account'   => true,
			'languages' => true,
			'panel'     => true,
			'site'      => true,
			'system'    => true,
			'users'     => true
		],

Renaming “settings” to “system” in all blueprints does the Job for me… @David - maybe you have the same error?

It seems that this commit from 2 week ago is causing the trouble… fix: Add `$key` for permissions deprecated call (#8253) · getkirby/kirby@6d8ad85 · GitHub

src/Cms/Helpers.php‎
+6-1Lines changed: 6 additions & 1 deletion
Original file line number	Diff line number	Diff line change
@@ -35,6 +35,11 @@ class Helpers
		// Passing `$category = null` to `Permissions::for()` is not supported
		'permissions-for-category-null' => true,

		// Setting undefined permission categories or actions is deprecated
		// and will be ignored in a future version. Custom permissions should
		// be registered via the `permissions` extension instead.
		'permissions-undefined' => true,

Hey @j54j6 ,
thanks for letting me know. i will test your solution tomorrow :slight_smile:

i can confirm, this fixed my problem :tada:

it has to do with the permissions validation change introduced with v5.5.0

every wrong typed permission now throws an error.