Problem/Motivation
Both Configuration Provider and Features provide ServiceProvider classes implementing ServiceModifierInterface::alter() to swap out the class of the config.installer service.
Because Features is later alphabetically, by default its implementation overwrites that of Configuration Provider.
Proposed resolution
Explicitly set module weight on install to a high value (100).
Remaining tasks
User interface changes
API changes
Data model changes
| Comment | File | Size | Author |
|---|---|---|---|
| #20 | 2800839.diff | 8.09 KB | trackleft2 |
Issue fork config_provider-2800839
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
Comments
Comment #2
nedjoComment #4
nedjoComment #6
nedjoIn #2625310: Address conflict with other modules over config.installer class the approach in features was changed to use a decorator. We now need to roll back the change made previously in this issue and instead switch to the same decorator pattern.
Comment #7
trackleft2Comment #9
trackleft2Added a PHPUnit test, however it requires a composer.json to add dev dependencies (features.)
Comment #10
trackleft2Comment #11
trackleft2The two composer jobs are failing due to the lack of a Drupal 11 compatible version of features.
Personally, I think having the ability to test interoperability between this module and features is valuable, however if features doesn't create a compatible release, we'll be stuck with broken jobs.
We could consider just copying the parts of features we need to test into our test module.
Comment #12
trackleft2Comment #15
joegraduateComment #16
anicho01 commentedI know this was just flagged, but we're having a conflict with Features over config provider 3.0.0-alpha3
Comment #17
trackleft2Hey there @anicho01 I've updated the merge requests, however it is difficult to test without a Drupal 11 compatible version of features...
Comment #18
mprell commented@trackleft2 this issue occurs (and I assume can be tested) when using the Features D11 compatibility fork
https://git.drupalcode.org/issue/features-3447460
Comment #20
trackleft2Features has a Drupal 11 release., so I've updated the merge request. Adding a static patch for your testing convenience. If the patch works for you, please mark as Reviewed and Tested by the Community.
Comment #21
mprell commentedUnfortunately I haven't been able to test this patch yet because alpha3 causes a separate regression: PreExistingConfigException during profile installation for any module shipping config/install/ files that overlap with dependency config. This affects all Features-generated modules in our distribution.
I've filed a new issue for this: https://www.drupal.org/project/config_provider/issues/3572966
Until that's resolved, I can't get far enough through site-install to test the decorator stacking behavior this patch addresses.