juju_exe() fails to parse JUJU_VERSION
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Juju Wait Plugin |
New
|
Undecided
|
Unassigned | ||
Mojo: Continuous Delivery for Juju |
Triaged
|
Medium
|
Unassigned |
Bug Description
Hi,
If you run mojo with the JUJU_VERSION environment variable set to "latest-1.25.x", mojo will try to run the "juju-latest" executable, which doesn't exist.
This is because juju_exe() (in mojo/juju/wait.py) is bugged, and is expecting JUJU_VERSION to have a proper formatting.
Not sure why this exists and why mojo doesn't simply use juju from PATH.
At any rate, this error should be caught up and displayed more appropriately, because right now, here's what's displayed :
2017-06-29 12:10:29 [INFO] Waiting for environment to reach steady state
2017-06-29 12:10:29 [ERROR] juju-latest status --format=json failed: 2
2017-06-29 12:10:29 [ERROR] Juju Status: environment: my-super-env
machines:
[juju status follows]
2017-06-29 12:10:29 [ERROR] 2
Not easy to understand what's going on :)
Thanks
(2 is ENOENT here, not actually the exit code of the process.)