Panel crashes after update to 2.5.6

After updating kirby panel and kirby core from 2.4.0 to 2.5.6 i get this error, when i log into the panel.

Method KirbyPanelView::__toString() must not throw an exception, caught Error: Call to a member function nextPageUrl() on null

i copied the files 2 times again and nothing changes.

Does anyone have any idea why this might be?

best regards

Your upgrading from a fairly old version of Kirby. Is your PHP version also old? Should be at least 5.4 but ideally version 7.

Have you set pages:false in your site.yml?

https://github.com/getkirby/panel/issues/1112

1 Like

Thank you very much, that was the reason.

@texnixe:

Issue https://github.com/getkirby/panel/issues/1112 is still open.

@bastianallgeier
@lukasbestle

It would be super great if this could be fixed soon. Many thanks!

HeinerEF

(Edited by @texnixe to make it sound more friendly than the original)

To be honest I don’t really understand what you are trying to say.

I run in this issue by updating an older develop site to the latest Kirby version.
This issue is older than the last Kirby version. So I think, it would be nice, if you can prevent this issue in the next Kirby version.

I thank the entire Kirby team and wish you a happy new year.

Ah, now I get it.
I can’t promise anything as there are also other issues we need to take care of, but we will try our best. :slight_smile:

Happy New Year! :fireworks:

1 Like

You can work around this issue by setting a limit:

site.yml

pages:
  limit: 10
  max: 25
1 Like

Thank you very much!

I had found that in another post here in the forum.

Added:

If I set the limit “max:” to 3, all is ok :slightly_smiling:, I cannot add pages:

site\blueprints\site.yml

...

pages:
  max: 3

...

I actually think this is the more correct way of dealing with this issue rather than setting pages to false. All that is left to do then is to make the first level pages undeletable.

Nobody can add anything, nobody can delete anything, and you can still access the page view to sort pages if that is allowed (which you can’t when setting pages: false.

I agree, but I still think we should fix pages: false so that it at least doesn’t throw an error but falls back to a behavior where no additional pages can be added. So basically pages: false should be an alias of max: 1 in the site blueprint.

1 Like