Trying to run a D7 to D10 migration, the process stops
LogicException: The currently known shared structure migrations do not have any dependencies. This assumption does not hold for focal_point_crop. It depends on: d7_file, d7_user, d7_user_role, d7_filter_format, d7_field_instance:field_collection_item:field_education, d7_field:field_collection_item, d7_node_type:article, [...], user_picture_field_instance, user_picture_field, user_picture_entity_display, user_picture_entity_form_display, focal_point_crop_type, focal_point_settings. in Drupal\acquia_migrate\Clusterer\Heuristics\SharedEntityStructure->matches() (line 181 of /var/www/docroot/modules/contrib/acquia_migrate/src/Clusterer/Heuristics/SharedEntityStructure.php).
I can solve this error by replacing in composer.json
"drupal/focal_point": {
"[AMA_MIGRATE_FIX] Issue #3267350: Migrate Focal Point module from D7 to D9.": "https://www.drupal.org/files/issues/2022-05-06/focal_point-migrate-3267350-28.patch"
},
by
"drupal/focal_point": {
"Migrate Focal Point module from D7 to D9.": "https://www.drupal.org/files/issues/2023-08-18/focal_point-migrate-3267350-31.patch"},
| Comment | File | Size | Author |
|---|---|---|---|
| #11 | Screenshot 2023-12-08 at 2.17.55 PM.png | 130.33 KB | wim leers |
Issue fork acquia_migrate-3393712
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:
- focal_point-3267350-31
changes, plain diff MR !15
- 3393712-apply-a-newer
changes, plain diff MR !10
Comments
Comment #2
wim leersThanks for the report!
This actually might mean that we'll need to refine #3267350: Migrate Focal Point module from D7 to D9..
But https://www.drupal.org/files/issues/2023-08-18/focal_point-migrate-32673... shows:
So where did all those other migration dependencies come from? Something must be setting them. It is impossible to reproduce without both your full Drupal 7 DB + your D9
composer.json.Please put a breakpoint in the logic that collects all migration definitions, and observe which alter hook is for example adding
d7_node_type:articleas a a migration dependency — because it definitely makes no sense that the focal point migration depends on that!Comment #3
vistree commentedHi Wim,
I don't really understand what you want me to do. It seems enough to make sure to use the latest patch from https://www.drupal.org/project/focal_point/issues/3267350
Acquia Migrate adds patch from #28
I replaced it with patch from #31 - and everything works fine ;-)
The other requirements seem to be related to my special D7 source. No real need to debug that one.
Comment #4
wim leersAhhh! 😄
I totally misunderstood your original report!
Can you please create a merge request against the
recommendationsbranch? 🙏😊 The 28-to-31 patch seems like a very reasonable, minor change 👍Looking forward to merging this!
Comment #7
wim leersAh yes, you _must_ create a merge request using the GitLab CI UI, because you need to target the
recommendationsbranch, not the1.8.xbranch. That's a bit confusing with the transition to GitLab CI… 😬Comment #8
vistree commentedSorry, I accidently pressed the "create MR" in this ticket - without even downloading the branch ;-(
What do I exactly need to do? In the branch I can't find any of the patches shown in my project. I guess, they are created by the alma script when installing the local Drupal 9 site and starting the initial migration.
Can I add the patch as normal to the composer.json within the root folder of the branch?
Comment #9
wim leersI'll take this on — this will serve as a sample MR for one of the most common patterns of changes then 👍
Comment #11
wim leersI followed the official handbook page for this process
Then after following the instructions here on the d.o issue to push my locally created branch to this issue's fork:
… followed by generating a merge request from this branch:
Now the CI pipeline is running to test it: https://git.drupalcode.org/project/acquia_migrate/-/pipelines/61079! 👍
Comment #12
wim leersNow we wait and see if the CI job passes! 👀
Comment #13
wim leersYay, that's green! 🟢
Once we merge this, then if the module's test suite runs again (currently the
1.8.xbranch), then if all is well, the "pinned recommendations" CI jobs should continue to apply the old patch, and the "next recommendations" CI jobs should apply the new patch 👍Our job here is done — the only reason I'm not yet merging this is to not disrupt #3406774: Update: drupal/core:9.5.11, which is more complicated. I'll land this after that 👍
Comment #14
wim leersRebased on top of #3406774: Update: drupal/core:9.5.11, and still passes, so 🚢!
Comment #16
wim leersComment #17
wim leersComment #18
vistree commentedThanx @Wim Leers !!
Comment #20
rajeshreeputrafocal_point issue #3267350: Migrate Focal Point module from D7 to D9. is now merged.