Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Over in #1808248: Add a separate module install/uninstall step to the config import process, we're messing with the ConfigImporter.
That apparently can break our install of default config during module install, which is just nuts.
This patch breaks the connection between 'install default config' and 'config import', so we can deal with the complexities of each without breaking the other.
Comment | File | Size | Author |
---|---|---|---|
#14 | interdiff.txt | 789 bytes | tayzlor |
#12 | 2095489-12.patch | 6.92 KB | tayzlor |
#12 | interdiff.txt | 788 bytes | tayzlor |
#9 | 2095489-9.patch | 6.84 KB | tayzlor |
#9 | interdiff.txt | 3.11 KB | tayzlor |
Comments
Comment #1
Anonymous (not verified) CreditAttribution: Anonymous commentedtagging.
Comment #2
Anonymous (not verified) CreditAttribution: Anonymous commentedhere's the patch.
i didn't git rm ConfigInstaller yet, that can be done after #2095115: delete ViewTestConfigInstaller and have ViewTestData create views, not 'import' them lands.
Comment #4
Anonymous (not verified) CreditAttribution: Anonymous commented#2: 2095489-2.patch queued for re-testing.
Comment #6
Anonymous (not verified) CreditAttribution: Anonymous commentednow with less durp durp durpal.
Comment #8
tim.plunkettThen you can straight up remove the ConfigInstaller class
Comment #9
tayzlor CreditAttribution: tayzlor commentedNew patch which removes the ConfigInstaller class and should hopefully fix the broken test in ConfigInstallTest.
I also added another line to reset the static cache (via the ConfigFactory) for the config name being imported in config_install_default_config() as other tests were failing and it seemed like this was because it was retrieving stale config items from there.
Comment #10
Anonymous (not verified) CreditAttribution: Anonymous commentedtayzlor++ i think this is RTBC, but it would be good to get alexpott to have a look at it.
Comment #11
alexpottWe need to call the ConfigFactory->enterContext before we do anything with config and we need to call ConfigFactory->leaveContext
Comment #12
tayzlor CreditAttribution: tayzlor commentedNew patch attached which switches in and out of context around the config saving.
Comment #13
tayzlor CreditAttribution: tayzlor commentedComment #14
tayzlor CreditAttribution: tayzlor commentedWrong interdiff uploaded but the patch is still good - so ignore the interdiff in #12
Comment #16
tayzlor CreditAttribution: tayzlor commented#12: 2095489-12.patch queued for re-testing.
Comment #18
Anonymous (not verified) CreditAttribution: Anonymous commentedbump.
Comment #19
Anonymous (not verified) CreditAttribution: Anonymous commentedanother reason to do this: #2069373: Race conditions on import if CUD on ConfigEntity A triggers changes in ConfigEntity B can't do the obvious thing, because we run import code during install, so the 'don't create fields' flag gets set, and no default config entities get extra fields, breaking all the things.
Comment #20
alexpottFinally got a pass let's get this done
Comment #21
catchCommitted/pushed to 8.x, thanks!
Comment #22
swentel CreditAttribution: swentel commentedSo this is fixed then I guess :)
Comment #24
xjm