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.
Problem/Motivation
The update status is tracked by checklistapi.progress.thunder_updater.yml
but configuration must not contain state information, as documented in several docs: https://www.drupal.org/docs/8/api/configuration-api
This causes that in a common workflow export + git commit + import
can deploy the status as update completed without have been run the updates.
Proposed resolution
Use state API instead of configuration in thunder_updater
Comments
Comment #2
sunYes. Thanks for creating this issue, @quiron.
Comment #3
daniel.bosenThanks for reporting! At first glance I would guess, this is a checklist api issue? Independend of that, isn't the real issue, that you do not call the update hooks on production in your workflow?
Even if the checklistapi would save its status in the State API, that would not solve the problem, that you import configuration to production, that expects update hooks to be executed. And I am not talking about the rather unimportand checklist configuration, but about the whole configuration. What we could provide is a general warning when we see that update hooks have not been executed, which is always bad.
Otherwise I am with you, it looks like checklistapi should propably save its status in state API, but maybe it is a better idea to discuss that in the checklist api issue cue.
Comment #4
quironThanks for answering!
Issue created to Checklist API plugin: https://www.drupal.org/project/checklistapi/issues/2944103
And about the updates execution, of course, we run it, the point is that the update results have to be exported too (p.e. module (dis/)activation), but as you said this isn't the real bug.
Anyway, the idea of the warning looks good to me.
Comment #5
daniel.bosenUsually we found this order to be necessary to update anything in Drupal 8:
On dev installation (assuming active configuration and config files are in sync):
On deploy to production:
Comment #6
chr.fritsch#2944103: Add the ability to use State API instead of Configuration API to store checklist progress is fixed, so I asked for a checklist release.
Comment #7
chr.fritschPostponed on a new checklist API release.
Comment #8
chr.fritschThis is now an update_helper issue because everything is moved there.
Comment #9
mtodor CreditAttribution: mtodor at Thunder commentedThere is PR for update helper that would migrate progress storage from config to state.
Here: https://github.com/BurdaMagazinOrg/module-update_helper/pull/10
Comment #10
mtodor CreditAttribution: mtodor at Thunder commentedThis PR is merged long time ago and also released, so the issue can be closed.
Thanks, everyone.