Deployer: KeyError: 'uuid' connecting to environment

Bug #1608952 reported by Curtis Hovey
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
juju-core
Invalid
High
Ian Booth
juju-deployer
Invalid
Undecided
Unassigned
python-jujuclient
Fix Released
High
Tim Van Steenburgh

Bug Description

As seen at
    http://reports.vapour.ws/releases/issue/57a0a18a749a566a48473c0f

deployer.env: Connecting to environment...
Traceback (most recent call last):
  File "/usr/local/bin/juju-deployer", line 9, in <module>
    load_entry_point('juju-deployer==0.8.0', 'console_scripts', 'juju-deployer')()
  File "/usr/local/lib/python2.7/dist-packages/juju_deployer-0.8.0-py2.7.egg/deployer/cli.py", line 140, in main
    run()
  File "/usr/local/lib/python2.7/dist-packages/juju_deployer-0.8.0-py2.7.egg/deployer/cli.py", line 250, in run
    importer.Importer(env, deployment, options).run()
  File "/usr/local/lib/python2.7/dist-packages/juju_deployer-0.8.0-py2.7.egg/deployer/action/importer.py", line 301, in run
    self.env.connect()
  File "/usr/local/lib/python2.7/dist-packages/juju_deployer-0.8.0-py2.7.egg/deployer/env/go.py", line 88, in connect
    self.client = self.client_class.connect(self.name)
  File "build/bdist.linux-x86_64/egg/jujuclient/environment.py", line 87, in connect
  File "build/bdist.linux-x86_64/egg/jujuclient/connector.py", line 41, in run
  File "build/bdist.linux-x86_64/egg/jujuclient/juju2/connector.py", line 53, in parse_env
KeyError: 'uuid'
2016-08-02 11:16:26 INFO cmd supercommand.go:465 command finished
2016-08-02 11:16:26 ERROR Command '('juju', '--debug', 'deployer', '-e', 'aws-deployer-bundle:aws-deployer-bundle', '--debug', '--deploy-delay', '10', '--timeout', '3600', '--config', '/var/lib/jenkins/repository/scale2-lxd-alt-path.yaml')' returned non-zero exit status 1

Revision history for this message
Tim Van Steenburgh (tvansteenburgh) wrote :

juju-deployer-0.8.0 won't work with beta14, you need to use 0.9.0

Revision history for this message
Tim Van Steenburgh (tvansteenburgh) wrote :

Please paste the output of this command:

    juju get-model-config -m aws-deployer-bundle:aws-deployer-bundle --format=yaml

Revision history for this message
Curtis Hovey (sinzui) wrote :
Changed in juju-core:
assignee: nobody → Ian Booth (wallyworld)
Revision history for this message
Curtis Hovey (sinzui) wrote :

@Tim

extracted-bin/usr/lib/juju-2.0-beta14/bin/juju get-model-config -m aws-deployer-bundle:aws-deployer-bundle --format=yaml
agent-metadata-url:
  value: http://juju-dist.s3.amazonaws.com/parallel-testing/agents
  source: model
agent-stream:
  value: revision-build-4201
  source: model
agent-version:
  value: 2.0-beta14
  source: model
apt-ftp-proxy:
  value: ""
  source: default
apt-http-proxy:
  value: ""
  source: default
apt-https-proxy:
  value: ""
  source: default
apt-mirror:
  value: ""
  source: default
automatically-retry-hooks:
  value: true
  source: default
default-series:
  value: trusty
  source: model
development:
  value: false
  source: default
disable-network-management:
  value: false
  source: default
enable-os-refresh-update:
  value: true
  source: default
enable-os-upgrade:
  value: false
  source: model
firewall-mode:
  value: instance
  source: default
ftp-proxy:
  value: ""
  source: default
http-proxy:
  value: ""
  source: default
https-proxy:
  value: ""
  source: default
ignore-machine-addresses:
  value: false
  source: default
image-metadata-url:
  value: ""
  source: default
image-stream:
  value: released
  source: default
logforward-enabled:
  value: false
  source: default
logging-config:
  value: <root>=DEBUG;unit=DEBUG
  source: model
no-proxy:
  value: ""
  source: default
provisioner-harvest-mode:
  value: destroyed
  source: default
proxy-ssh:
  value: false
  source: default
region:
  value: ap-southeast-1
  source: model
resource-tags:
  value: {}
  source: model
ssl-hostname-verification:
  value: true
  source: default
test-mode:
  value: true
  source: model
vpc-id:
  value: ""
  source: model
vpc-id-force:
  value: false
  source: model

tags: added: blocker
Revision history for this message
Ian Booth (wallyworld) wrote :

get-model-config no longer prints the model uuid, since uuid is not a user config attribute. We are restricting model-config to showing those attributes a user can set or which are inherited from the controller or cloud region. This is part of the new improved juju model config feature.

The (new) correct way to get the model uuid is to run juju show-model.

Apologies for the deployer breakage - I didn't realise any callers were relying on extracting model uuid in this way.

Changed in juju-core:
status: Triaged → Invalid
Revision history for this message
Ian Booth (wallyworld) wrote :

For reference, here's a sample output of show-model

juju show-model
foo:
  name: foo
  model-uuid: 39c33b47-32d5-4cc4-84ca-13687d94e45a
  controller-uuid: 3880f528-8db0-44cd-8a45-999196e83c10
  owner: admin@local
  cloud: lxdtest
  type: lxd
  life: alive
  status:
    current: available
    since: 20 hours ago
  users:
    admin@local:
      display-name: admin
      access: admin
      last-connection: just now

Changed in juju-deployer:
status: New → Invalid
Changed in python-jujuclient:
status: New → In Progress
assignee: nobody → Tim Van Steenburgh (tvansteenburgh)
importance: Undecided → High
milestone: none → 0.53.1
Changed in python-jujuclient:
status: In Progress → Fix Committed
Revision history for this message
Tim Van Steenburgh (tvansteenburgh) wrote :

python-jujuclient 0.53.1 in ppa:tvansteenburgh/ppa

Changed in python-jujuclient:
status: Fix Committed → Fix Released
Revision history for this message
Curtis Hovey (sinzui) wrote :

Thank you. Juju CI has the new package. Test pass.

Curtis Hovey (sinzui)
Changed in juju-core:
milestone: 2.0-beta14 → none
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.