- Issue created by @scotwith1t
- πΊπΈUnited States pcate
Doing a test upgrade from v2.3.1 to v3.3.2 I ran into this same error.
- πΊπΈUnited States pcate
Any
language.content_settings.group_content.*
config files were also not updated. Some of those include the ones with hashed ID's so I'm not sure if updating the language config files needs to be part of the update hook to prevent config dependency errors. - π§πͺBelgium kristiaanvandeneynde Antwerp, Belgium
Updated the fixture and can confirm, will see what I can do.
- Merge request !199Updated fixture so it also runs on newer versions, added long named content... β (Merged) created by kristiaanvandeneynde
- π§πͺBelgium kristiaanvandeneynde Antwerp, Belgium
MR added, now I need to figure out why the IDs weren't adapted. Although I recall being against that because changing a bundle name has all sorts of extra implications. So I think the idea was to keep the old bundle names, but then the code needs to be able to deal with that.
- π§πͺBelgium kristiaanvandeneynde Antwerp, Belgium
Okay, so we're always going to set a group_update_10300_detected_legacy_version state key now and leverage that in GroupRelationshipTypeStorage::getRelationshipTypeId(). This means older sites will be slightly slower as we cannot be sure there what the relationship type ID is.
Will try to take care of this as neatly as I can.
- π§πͺBelgium kristiaanvandeneynde Antwerp, Belgium
Needs tests for new approach, but basically we now have:
- A state key set during the updates that keeps track of whether we came from a legacy version (v1/v2)
- A check for said key when trying to form a relationship type ID
- If the check passes, we try to load the old ID
- If the check fails or no old ID was found, we use the new ID pattern
You can already try the MR out if you wish. I'll only commit it once we have tests, though.
- π§πͺBelgium kristiaanvandeneynde Antwerp, Belgium
Updating IS to reflect the real problem, we may need to double-check the upgrade guide and specifically mention that old IDs are fine, even if a bit confusing.
- π§πͺBelgium kristiaanvandeneynde Antwerp, Belgium
Right, added tests to prove this works. Just need to check the update guide now to make sure we got all bases covered.
- π§πͺBelgium kristiaanvandeneynde Antwerp, Belgium
I've updated the guide here: https://www.drupal.org/docs/extending-drupal/contributed-modules/contrib... β
At this point it would be nice if anyone could confirm that the changes here improve the upgrade path, then I can commit it and tag a new release.
- πΊπΈUnited States pcate
@kristiaanvandeneynde I just ran a test upgrade from v2 to v3 with this MR and it resolved the error.
-
kristiaanvandeneynde β
committed fc030dd5 on 3.3.x
Issue #3489243 by kristiaanvandeneynde, pcate, scotwith1t: The upgrade...
-
kristiaanvandeneynde β
committed fc030dd5 on 3.3.x
- π§πͺBelgium kristiaanvandeneynde Antwerp, Belgium
Thanks for the steps to reproduce and confirmation. Normally I don't easily assign credit for these types of comments, but given the impact I think quick responses ought to be rewarded.
Automatically closed - issue fixed for 2 weeks with no activity.