charm can not be deployed with ppa:landscape/18.03 on xenial
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
landscape-client-charm |
New
|
Undecided
|
Unassigned |
Bug Description
charm install issue with we are using ppa:landscape/18.03
2018-10-09 19:47:02 DEBUG juju.worker.
2018-10-09 19:47:02 DEBUG juju.worker.uniter agent.go:17 [AGENT-STATUS] executing: running config-changed hook
2018-10-09 19:47:03 DEBUG config-changed Traceback (most recent call last):
2018-10-09 19:47:03 DEBUG config-changed File "/var/lib/
2018-10-09 19:47:03 DEBUG config-changed from common import (
2018-10-09 19:47:03 DEBUG config-changed File "/var/lib/
2018-10-09 19:47:03 DEBUG config-changed from landscape.
2018-10-09 19:47:03 DEBUG config-changed ImportError: No module named landscape.
2018-10-09 19:47:03 ERROR juju.worker.
2018-10-09 19:47:03 DEBUG juju.machinelock machinelock.go:180 machine lock released for uniter (run config-changed hook)
2018-10-09 19:47:03 DEBUG juju.worker.
landscape-client:
charm: cs:xenial/
series: xenial
options:
account-name: "standalone"
origin: ppa:landscape/18.03
landscape-server:
charm: *landscape-charm
series: xenial
bindings:
"": *oam-space
options:
source: ppa:landscape/18.03
key: 4652B4E6
num_units: 3
to:
- 27
- 32
- 35
The issue here is that ppa:landscape/18.03 installs python3 libs whereas Juju uses Python 2.7 to execute its charms. So, we can see errors like:
ImportError: No module named landscape. configuration
And when we search for landscape packages we find them under python3 dist-packages:
$ dpkg-query --listfiles landscape-client | grep configuration python3/ dist-packages/ landscape/ client/ configuration. py
/usr/lib/
The viable work-around is to pin on 17.03 as long as charms run on python 2.7.