While working on #543550: Drush interactive mode I've seen a weird behaviour: help command works fine the first time it is invoked but it fails on a second invocation with an error of DRUSH_COMMAND_INSUFFICIENT_BOOTSTRAP.

It happens due to a strict check done at drush_enforce_requirement_bootstrap_phase(&$command):

if ($command['bootstrap'] == $current_phase) {
    return TRUE;
  }

In current drush usage this is not a problem at all but in order to introduce the interactive mode, it is needed to do a lesser check (<=) because we stay in the same drush "session" and a higher bootstrap phase could already been reached by a previous command.

On the other hand this change does not affect non-interactive drush usage AFAIK. So please consider applying the attached patch :)

Comments

jonhattan’s picture

Title: Aloow to run a command if required bootstrap phase is lower or equal to current phase. » Allow to run a command if required bootstrap phase is lower or equal to current phase.

fixing typo in issue title.

moshe weitzman’s picture

Status: Needs review » Fixed

committed.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.