Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[site:install] Exitcode 0 even when some error occurs #4079

Closed
zoiosilva opened this issue Jun 6, 2019 · 0 comments · Fixed by #4080
Closed

[site:install] Exitcode 0 even when some error occurs #4079

zoiosilva opened this issue Jun 6, 2019 · 0 comments · Fixed by #4080

Comments

@zoiosilva
Copy link
Contributor

Problem/Motivation

The command should return a non-zero value when there is a problem like a php extension missing, or the site is already installed.

Details to include:
If we put the command on a CI pipeline, it is desirable to get a proper error code to avoid false positive situations.

How to reproduce

  • Run the site-install command on an already installed drupal site;
  • run echo $? to see the error code;
  • The proper error code should at least be 1, not 0;

Details to include:

  • Console version: 1.8.0.
  • Console Launcher version: 1.8.0.

Solution

My suggestion is that we get the return value of the runInstaller in this line:

$this->runInstaller($database_install, $uri);

And return it right away if it's not zero.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant