5

I keep getting this error : Unable to load class \Drush\VersionControl\Backup every time i attempt to update my Drupal install from 8.4.0 to 8.4.2.

I am running the composer provided drush Drush Version : 8.1.15

Now here is what i have tried:

  • drush up drupal --debug
    Unable to load class \Drush\VersionControl\Backup

  • drush up drupal --debug --version-control=svn
    No valid version control or backup engine found

  • drush up drupal --debug --version-control=git
    No valid version control or backup engine found

  • drush up drupal --debug --no-backup
    No valid version control or backup engine found

if anyone could answer any of these question for me, i would really appreciate it: How do i turn off version control? How do i set the valid version control that this thing is complaining about? How do i set the backup engine?

Note: some solutions out there mentioned that we have to remove the composer provided version and install drush to a different location. To be honest I do not want to use that solution.

Thanks.

2

3 Answers 3

4
+50

I am running the composer provided drush Drush Version : 8.1.15

Drupal 8.4 requires Drush 9, so upgrade your Drush for starters.

composer global require drush/drush:master 

enter image description here http://docs.drush.org/en/master/install/

4
  • 1
    AFAIK that's not true anymore, the 8.4 incompatibility has been fixed with Drush 8.1.15
    – Hudri
    Jan 23, 2018 at 8:08
  • @Hudri one would think that in that case the info shown in the above screenprint would have been updated also, no? Jan 26, 2018 at 7:53
  • @Perrie.Vriens I've multiple sites running with Drupal 8.4.x and Drush 8.1.15, and so far I've not found any issues. I know the description hasn't been updated, but it just works for me. Also so github.com/drush-ops/drush/issues/3023
    – Hudri
    Jan 26, 2018 at 7:58
  • 1
    @Hudri Imagine an airplane with automatic pilot software based on Drupal 8.4, using Drush 8.x. How would you feel flying at 30,000 feet knowing the instructions of the manufacturer of the airplane state it has to be Drush 9? E.g. because nobody ever tested it enough with Drush 8.x? PS to OPer: congratulations with the bounty ! Jan 31, 2018 at 9:07
0

Install drush globally.

composer global require drush/drush:8.x

Works on Drupal 7 and 8.

You might have trouble locating the drush file to run as it will be at another location now. You can try to find it by running composer global show drush/drush Ideally change your PATH: settings to this.

-1

Remove Drush from the project composer and use globally installed Drush.

While working on a Drupal 7 install, with Drush 8 and using Drush launcher.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.