-
Notifications
You must be signed in to change notification settings - Fork 641
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[4.x]: Deleting Sites and Site-Group throws an "Undefined array key 2" error, when trying to open an entry. #14373
Comments
Could solve the issue myself. |
@hhentschel Can you try searching your logs for that error message ( |
@brandonkelly That's what I found in the web.log. error message and stack trace.
|
Hey, I have the same issue - when the site removal is applied via project config. I think it only applies to pages that have matrix on them. Would be happy about some hints how to tackle this, as I need to apply this change via project-config |
Sorry, missed your last response @hhentschel. Thanks for posting that. Believe I just fixed this for the next releases. @maxstrebel you can test by changing your
Then run |
Thanks @brandonkelly – that seems to do the job 🙏 |
Great, thanks for confirming! |
Craft 4.9.7 and 5.1.9 are out now with that fix. |
Hey Brandon - thank you for doing the fix so quickly. I work on the project with @maxstrebel. Unfortunately I noticed the following behaviour:
If I do the following:
Why I think it can be related to that issue -> If I do the following:
I end up with the same php error: Undefined array key 1 related to the sites. I have a hard time making sense of it. Do you think this issue could be related? |
I think we might have committed to early. The generation of the YAML files takes very long in this project. I just thought I can reproduce but after a minute the deleted files were recreated. We will test this together tomorrow morning and write again. |
What happened?
Description
I updated to latest version (4.7.2.1) and deleted some sites and one site group I don't need anymore.
I also changed site name handles.
After that, I cannot open entries in the control panel. Seems that Site ID are mixed up or something.
It gives a php error: Undefined array key 2
Steps to reproduce
I tried to resave entries via cli but get the same error there.
Craft CMS version
4.7.2.1
PHP version
8.1.27
Operating system and version
MacOS X 13.21.1
Database type and version
MariaDB 10.6.16
Image driver and version
Imagick 3.7.0 (ImageMagick 7.1.0-62)
Installed plugins and versions
CKEditor | 3.6.0
CP Field Inspect | 1.4.4
Expanded Singles | 2.0.5
ImageOptimize | 4.0.5
Image Resizer | 3.0.9
Neo | 4.0.2
QRCode | 2.1.0
SEOmatic | 4.0.37
Twigpack | 4.0.0-beta.4
The text was updated successfully, but these errors were encountered: