Problem/Motivation

After updating Migrate Tools to the latest 6.x version, this module throws a fatal error:

Error: Class "Drupal\migrate_tools\Commands\MigrateToolsCommands" not found in include() (line 25 of /app/web/modules/contrib/migrate_orphans/src/Commands/MigrateOrphansCommands.php).

Since this is a B/C break, we should probably start a new minor (1.1.0) or even major (2.0.0) version.

CommentFileSizeAuthor
#5 migrate_orphans-3378229-5.patch1.08 KBkensae
Command icon 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

pfrenssen created an issue. See original summary.

pfrenssen’s picture

Status: Active » Needs review

This is ready for review. I cannot currently create a merge request because the project is missing a dev release, but the code is in https://git.drupalcode.org/issue/migrate_orphans-3378229/-/compare/1.0.x...

ayalon’s picture

I have created a DEV release but I cannot find a way to merge your changes. Can you create a merge request? Then I will merge the change into dev and tag a new release.

ayalon’s picture

Status: Needs review » Reviewed & tested by the community
kensae’s picture

StatusFileSize
new1.08 KB

I've created a patch from the issue fork. I had to remove the changes from the .info.yml file, because they caused the patch to fail because of the following issue: https://www.drupal.org/project/drupalorg/issues/3066468

pfrenssen’s picture

Thanks! I have also made the merge request.

pfrenssen’s picture

@kensae FYI the patch posted in #5 is not complete without the change to the .info.yml file. This is needed to avoid a backwards compatibility break with Migrate Tools 5. The complete patch is in the MR: https://git.drupalcode.org/project/migrate_orphans/-/merge_requests/3.diff

If you have trouble with applying the patch on packaged releases then you can use the issue fork directly in composer.json:

    "repositories": [
        {
            "type": "composer",
            "url": "https://packages.drupal.org/8",
            "exclude": ["drupal/migrate_orphans"]
        },
        {
            "type": "package",
            "package": {
                "name": "drupal/migrate_orphans",
                "_readme": "Revert to the stable release once https://www.drupal.org/project/migrate_orphans/issues/3378229 is fixed.",
                "version": "1.1.0",
                "source": {
                    "url": "https://git.drupalcode.org/issue/migrate_orphans-3378229.git",
                    "type": "git",
                    "reference": "3378229"
                },
                "type": "drupal-module"
            }
        },
    ]
pfrenssen’s picture

sandervancamp’s picture

@kensae, seg merci he

tvalimaa’s picture

That patch worked, thx

cbessire’s picture

#9 worked perfectly for me.

ayalon’s picture

As proposed, I have created a new major version supporting Migrate 6. Thanks for all the contribution and testing.

ayalon’s picture

Status: Reviewed & tested by the community » Fixed
ayalon’s picture

Status: Fixed » Closed (fixed)