Action doesn't correctly translate unit name into tag if hyphen present
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
juju-core |
Won't Fix
|
Undecided
|
Unassigned | ||
python-jujuclient |
Confirmed
|
Undecided
|
Unassigned |
Bug Description
The Action.
enqueue_
However this fails:
enqueue_
In the latter case, I think the name ends up being converted by unitTagSuffixToId() as my/machine/0. In addition perhaps the unitSTagSuffixToId function (names/unit.go) should have a check that a / doesn't already exist in the tag?
I believe the proper fix is to replace the '/' with a '-' in enqueue_units() whet the unit- is appended.
Changed in juju-core: | |
status: | New → Won't Fix |
Changed in python-jujuclient: | |
status: | New → Confirmed |
This is not a juju-core issue, but it's caused by this line in python-jujuclient:
http:// bazaar. launchpad. net/~juju- deployers/ python- jujuclient/ trunk/view/ head:/jujuclien t.py#L1890
The client assumes any unit passed to enqueue_units should be a unit tag (unit-my-unit-0), not a name (my-unit/0).
The conversion from a name to a tag is handled correctly in juju-core, but when using the API tags are expected instead of names.