Islandora-Collaboration-Group / ISLE

Islandora Enterprise (ISLE) is a community project that addresses two of the most significant pain-points in Islandora: installation and maintenance.
https://Islandora-Collaboration-Group.github.io/ISLE/
GNU General Public License v3.0
32 stars 34 forks source link

Drush crashes due to IMI use of Composer in install-local-migrate process at Step 10 #374

Closed Digital-Grinnell closed 3 years ago

Digital-Grinnell commented 4 years ago

Issue description

I'm working again through install-local-migrate and my migration-site-vsets.sh script is crashing with multiple fatal errors because drush won't run. The cause is a missing include file required by the Islandora_Multi-Importer (IMI) module. You must run composer update in the IMI module in order to properly install or re-install it. Until you do, drush won't work.

For an issue, describe steps to reproduce the issue

System setup (OS information, software versions, etc): Mac OS X

Steps:

  1. Follow install-local-migrate.md through steps 1-9.
  2. In Step 10, the command that runs the migrate-sites-vsets.sh script will crash with multiple fatal errors like this:

Drush command terminated abnormally due to an unrecoverable error. [error] Error: require_once(): Failed opening required '/var/www/html/sites/all/modules/islandora/islandora_multi_importer/vendor/autoload.php' (include_path='.:/usr/share/php') in /var/www/html/sites/all/modules/islandora/islandora_multi_importer/islandora_multi_importer.module, line 19

What's the expected result?

There should be NO fatal errors when running the aforementioned script.

What's the actual result?

See above.

Additional details / screenshots

I believe this is only an issue if one is migrating from an Islandora installation that previously used, or uses, the Islandora_Multi-Importer module. It is the only module that I know of which relies on Composer for installation.

noahwsmith commented 4 years ago

I guess you could add to migrate-sites-vsets.sh something that looks for the presence of the IMI module and runs composer install if it finds it, but I don't otherwise see how the ISLE project can enforce a fix within an institution's drupal codebase. Thoughts @Digital-Grinnell ?

SummittDweller commented 4 years ago

Right, what I did was add a loop at the top of that script that finds composer.lock files and runs composer update against each one. Seems to work nicely, and does no harm if there are no composer installed components.

On Mar 23, 2020, at 2:46 PM, Noah W. Smith notifications@github.com wrote:

I guess you could add to migrate-sites-vsets.sh something that looks for the presence of the IMI module and runs composer install if it finds it, but I don't otherwise see how the ISLE project can enforce a fix within an institution's drupal codebase. Thoughts @Digital-Grinnell https://github.com/Digital-Grinnell ?

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/Islandora-Collaboration-Group/ISLE/issues/374#issuecomment-602817817, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAHKYC2XYWEDZELXKHRO7RLRI64CJANCNFSM4LEMY5DA.

g7morris commented 3 years ago

Hi @SummittDweller aka Mark ;)

Would you like to submit a PR with that loop for the next ISLE release?

We'd love to give you credit and a big thanks for this!

Hope you are well.

Cheers Gavin

Digital-Grinnell commented 3 years ago

I'd love to create a PR, but don't have time right now, nor anytime soon. Sorry. In case you would like to pick up the change though, I've attached a copy of my migration_site_vsets.sh as a .txt file here. I think the only change in the file is near the top, and it's clearly marked with a comment.

Thanks.

migration_site_vsets.txt

g7morris commented 3 years ago

Closing as "fixed" from ISLE 1.5.5 release & @McFateM & @SummittDweller credited. Thanks Mark!