Migrations often do not exist or can't be found

Created on 20 February 2017, over 7 years ago
Updated 6 September 2023, about 1 year ago

I keep running into cases where commands (migrate-import, migrate-status) cannot find migrations. Usually I'm trying to run a migration, so I start with mi and then run ms when that is not found, which results in an empty result. This especially happens when using the same DB/code/config on a different host (develop locally, put everything on staging, then migrations not found).

I have tried diagnosing a bit and have noticed:

  • All of the modules necessary are installed (migrate, migrate_tools, my migrate module, etc)
  • I have tried the service calls with code from #2832199 and #2795447 but the following is empty:
$manager = \Drupal::service('plugin.manager.migration');
$plugins = $manager->createInstances([]);
var_dump(array_keys($plugins));

This may be heavily related to the issues above, but I'm trying to assess if there is a way for me to get this working.

Drupal version: 8.2.6

πŸ› Bug report
Status

Postponed: needs info

Version

6.0

Component

Drush commands

Created by

πŸ‡ΊπŸ‡ΈUnited States rballou

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

  • πŸ‡§πŸ‡ͺBelgium tvb

    Chiming in with my case:

    If you use a custom source plugin, make sure source_module in the annotation is set to an enabled module in the source site.

    drush migrate:import <migration_id> will just report "No migrations found", while log messages contains a message "Migration did not meet the requirements." with mention of the offending source_module.

  • πŸ‡¬πŸ‡·Greece TheodorosPloumis Greece

    Had the same issue when installed the taxonomy_machine_name β†’ module.

Production build 0.71.5 2024