-
Notifications
You must be signed in to change notification settings - Fork 642
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]: IntegrityException when Saving Entry w/ Matrix #11155
Comments
Not able to reproduce this. Any chance you can send in a database backup, your Composer files, and steps to reproduce, to [email protected]? |
I experience the same, thought at first that this would be a Neo issue, but it turns out I have the same issue with Matrix blocks:
Here are the affected fields and sections, but I can provide more data if needed. Also, it happens after a few successful saves, not with the first one. Totally random, sometimes after hours of editing, sometimes after the second save. Steps to reproduce
I couldn't find a pattern yet. |
I have the same error when saving an entry with a matrix field:
I'm on Windows 11 with MariaDB 10.6.5, PHP 8.0.18, Craft 4.0.2. I have sent an email with my database and composer.json/composer.lock to [email protected]. |
@leigeber Did you mean |
It does happen sometimes even without Matrix fields. I just set up a fresh installation, created an page entry type with a tab without Matrix field and the exception occured (just once this time) The field setup:
Setup:
I'm using NItro (latest) |
@elfacht Please check the actual error message carefully. It’s almost certainly not the same as this one. And assuming it’s not, please post it as a new GH issue, with as much info as you can, including the full error message and the stack trace that should get logged in |
Here is the stack trace for me:
|
@brandonkelly I created a new issue here: #11220 which is similar and probably the error that you had @elfacht. |
Yes, not present in the craft_matrixblocks table but they are in the craft_elements table. Shooting a zip to support now. Thanks. |
Got to the bottom of this and fixed for the next release! To get the fix early, change your |
Craft 4.0.3 is out now with that fix. |
What happened?
Description
On an entry that includes a Matrix, we're unable to save. The exception is as follows:
The 76030, 76031, etc IDs do exist as elementIds on the craft_matrixcontent_homefeatures table but no reference in craft_matrixcontent. Testing the entry in other environments it seems certain edits will trigger the problem, for instance adding a new Matrix block but possibly other edits on other non-Matrix fields in the entry.
Once triggered even if you discard the changes the entry will continue to fail saving.
Craft CMS version
4.0.1
PHP version
8.1.0
Operating system and version
No response
Database type and version
PostgreSQL 13.4
Image driver and version
No response
Installed plugins and versions
The text was updated successfully, but these errors were encountered: