Juju 3.0 breaks a significant amount of documentation by renaming high-usage commands including run, upgrade-charm, add-relation, run-action
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Canonical Juju |
Confirmed
|
Undecided
|
Unassigned |
Bug Description
Juju 3.0 was released over the weekend to latest/stable. It seems latest/stable has since been reverted to 2.9 again however many internal and customer machines have already updated and don't roll back automatically.
Several high-usage commands has been renamed or removed that are in *significant* amounts of documentation.
To my observation there was no deprecation warning about this in the previous versions and the old commands now error out with no helpful message. This is going to be hugely impactful to customers and automated/scripted testing environments.
It seems at least some of these changes have been in planning for 12-24 months since at least 2.8:
https:/
However many others seem to have been done at the last minute in the last couple of weeks before the release:
https:/
Given the amount of user-facing documentation referencing these commands it seems like a better deprecation policy is needed and we a serious reconsideration on these changes for 3.0 is required. There were also some unanswerred comments along these lines in both of the linked PRs.
For some commands you could have a compatible old command as the old command no longer eixsts, however, the "juju run"/"juju exec" switch and "juju run-action"/"juju run" switch are problematic.
I also note that you now get errors and the "Did you mean:" output does not actually inform you of the new command, e.g.:
$ juju run-action -h
ERROR juju: "run-action" is not a juju command. See "juju --help".
Did you mean:
show-action
The main ones I have so far observed:
= juju run =
Renamed to 'juju exec'.
A lot of documentation uses 'juju run --unit/u' or 'juju run --application/-a' for various tasks.
In my ~/src/charms with 182 repos of primarily Openstack charms: 80 mentions.
Likely many more in KBs, other repos, automation scripts, etc.
= juju run-action =
Renamed to 'juju run'
280 mentions in my ~/src/charms
= juju add-relation =
Renamed to 'juju relate'
486 mentions in my ~/src/charms
= juju upgrade-charm =
Renamed to 'juju refresh'
33 mentions in my ~/src/charms
= juju bootstrap --no-gui =
Least important one honestly but this switch was removed and was used in a lot of automated testing deployments to speed up bootstrap. So noted here.
References:
https:/
https:/
https:/
tags: | added: canonical-is canonical-is-upgrades |
Changed in juju: | |
status: | New → Confirmed |
tags: | added: sts |
tags: | added: canonical-bootstack |
summary: |
Juju 3.0 breaks a significant amount of documentation by removing or - renaming high-usage commands including "juju run", "juju upgrade-charm" - and "juju add-relation" + renaming high-usage commands including run, upgrade-charm, add-relation, + run-action |
summary: |
- Juju 3.0 breaks a significant amount of documentation by removing or - renaming high-usage commands including run, upgrade-charm, add-relation, - run-action + Juju 3.0 breaks a significant amount of documentation by renaming high- + usage commands including run, upgrade-charm, add-relation, run-action |
description: | updated |
To revert to the 2.9 CLI, the following command will force-downgrade back to the current 'latest/stable' (2.9.35 right now):
sudo snap refresh juju --classic
Alternatively you can specifically switch to the 2.9/stable channel but note this won't upgrade your CLI automatically in future (that may be a plus or minus): 2.9/stable --classic
sudo snap refresh juju --channel=