- Issue created by @dimitriskr
- Merge request !19Issue #3389340: Delete config action does not completely delete nested arrays β (Open) created by dimitriskr
- last update
about 1 year ago 32 pass - π¬π·Greece dimitriskr
With this first commit, I can remove anything under "rows:" but not itself
- π¬π§United Kingdom alexpott πͺπΊπ
@dimitriskr can you provide an automated test that shows the problem. Also I wonder which version of Drupal core generated the diff for the config update? There's a bug in Drupal 10.1.0 and up that will only be solved with the next patch release.
- π¬π§United Kingdom alexpott πͺπΊπ
@dimitriskr also thank you for the excellent bug report - they really help!
- π¬π·Greece dimitriskr
Thank you Alex
It's Drupal 9.5.11
Do you have a link of that bug in 10.1?
Also, about the test, just to confirm, I should write it in Kernel/UpdaterTest.php, right? - π¬π§United Kingdom alexpott πͺπΊπ
Kernel/UpdaterTest.php would be great. The 10.1.x bug was π DiffOpOutputBuilder does not correctly match the 10.0.x implementation and produces unexpected output Fixed - given you generated the update on 9.5.11 is not related at all.
- π¬π·Greece dimitriskr
Just to give you more data. The attached file is the one generated in `config/update`
You can see that it says to delete that part of the configuration(L59 on attached file), but it only does so for the last child items (result in IS)
- π¬π·Greece dimitriskr
Is this what you asked for?
The new test I created in this patch gets an error on editor schema on rows (locally), just like in the IS
Waiting for feedback :)
- last update
about 1 year ago 29 pass, 2 fail - Status changed to Needs review
about 1 year ago 10:06am 28 September 2023 - π¬π§United Kingdom alexpott πͺπΊπ
@dimitriskr this test is looking like what I'd expect. Given we're enabling so many additional modules I think that making this a new test specific to the 4 to 5 upgrade would be great. Also #10 appears to contain your fix but the error is still occurring?
- last update
about 1 year ago 29 pass, 2 fail - π¬π·Greece dimitriskr
That would be a mistake, I removed my "fixes" from the patch
What I wrote in #3 π Delete config action does not completely delete nested arrays Needs review is that it removes some child items, but not completely, resulting again in the same error. The last submitted patch, 12: config-update-ckeditor4-to-5-3389340-12--test-only.patch, failed testing. View results β
- codesniffer_fixes.patch Interdiff of automated coding standards fixes only.- Status changed to Needs work
about 1 year ago 12:16pm 28 September 2023 - π¬π·Greece dimitriskr
I think the original fix I wrote, would need a new approach.
Maybe the config-deletion could happen in one place, merging the "getFlatKeys()" with the "NestedArray:unsetValue()" and immediatelly compare with the base_config if an array is empty after deletion and unset it too. So it wouldn't delete "settings:" because "settings.plugins:" would still exist after the deletion, but remove completely "settings.toolbar:" and its data.
- last update
about 1 year ago 29 pass, 2 fail - last update
about 1 year ago 32 pass - π¬π·Greece dimitriskr
Here's a patch to test the new approach (check the MR) with the same test uploaded.
The only difference in the test is that I unset the "uuid" and "_core" from the new config. - last update
about 1 year ago 33 pass - Status changed to Needs review
about 1 year ago 7:28pm 28 September 2023 - π¬π·Greece dimitriskr
I also tested it on my distribution and the upgrade went smoothly.
If there's no comments on the MR changes, I believe this issue could go to RTBC - π¬π·Greece dimitriskr
I already have at least 2 installations reported the upgrade went fine with the MR patch with ckeditor5 is properly configured.
- First commit to issue fork.
- last update
12 months ago 32 pass - π¬π·Greece dimitriskr
- I don't know if we should move this issue to
NestedArray::unsetValue
to allow deleting the empty arrays after deleting their values, with a 4th parameter? - @maintainers, do you want this MR be moved towards 4.0.x branch?
- I don't know if we should move this issue to