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
Returning to CredentialForm after a rollback gives the following error.
Undefined index: pgsql in Drupal\migrate_upgrade\Form\MigrateUpgradeForm->buildCredentialForm() (line 743 of modules/migrate_upgrade/src/Form/MigrateUpgradeForm.php).
To reproduce:
- Perform an upgrade. I'm using a small D6 test site.
- When complete, return to /upgrade. Select Rollback.
- Perform the rollback
- When complete, click continue.
Comment | File | Size | Author |
---|---|---|---|
#4 | 2598900-4.patch | 1.87 KB | quietone |
Comments
Comment #2
mikeryanI can't reproduce this, with source DB and destination (DB) MySQL. What are your source and destination DB engines?
Comment #3
quietone CreditAttribution: quietone commentedThanks for trying. Both source and destination are MySQL and I've never done anything with the engines, so I guess the defaults.
I tried to track down the problem and only discovered more bad things. Nodes are not migrated at all for two D6 sites and D7 site hangs on taxonomy. So, until I find out what that is all about this will have to wait.
Maybe now is a good time to spin up a fresh container and rebuild. ;-)
Comment #4
quietone CreditAttribution: quietone commentedYes, this is still happening. I wonder what would happen if I also had PostGres installed. Anyway, the attached patch avoids the problem completely by only using the form advanced_options if it exists.
Comment #5
mikeryanNote #2606332: The migration form has hardcoded dependencies to database drivers, which is really the same problem. I now understand why pgsql is an issue, it's not going to be presented if you don't have Postgres installed and running (I installed it a long time ago and apparently it's still running, which explains why I don't see this issue).
So, the ideal patch is a combination of the two - the other patch puts the logic in the main loop over the drivers, yours makes sure it only does its work if the 'host' key is present, so I'll consolidate and give you both credit.
Comment #7
mikeryanDone, thanks!