juju / python-libjuju

Python library for the Juju API
Apache License 2.0
59 stars 99 forks source link

export_bundle does not contain whole model #384

Closed skatsaounis closed 4 years ago

skatsaounis commented 4 years ago
Python package: juju==2.7.1
Ubuntu package: juju 2.7.0-0ubuntu1~18.04.1~juju1

I am trying to export_bundle on a specific model and despite the model has many applications the export_bundle output stops at the option of one of the applications.

It is either a bug when an option of an application contains yaml or the model is very big.

Sample Code with omitted credentials:

from juju.controller import Controller
controller = Controller()
await controller.connect()
model = await controller.get_model('openstack')
bundle = await model.export_bundle()

Sample Output:

series: bionic
applications:
  ceilometer:
    charm: cs:ceilometer-268
    num_units: 3
    to:
    - lxd:95
    - lxd:94
    - lxd:92
    options:
      action-managed-upgrade: false
      enable-all-pollsters: true
      event-time-to-live: 300
      events-publisher: gnocchi
      openstack-origin: cloud:bionic-train
      pipeline-yaml: |
         <-----At this point it breaks the output (it has the spaces been written)

NOTE: If I fetch the model.applications I can find all of my model applications.

SimonRichardson commented 4 years ago

This is an issue with Juju directly, so I'm closing this and you can track the PR https://github.com/juju/juju/pull/11135, we're expecting this to be released ASAP once it's landed.

Please feel free to re-open it if you have any questions. Thank-you.

skatsaounis commented 4 years ago

Hi @SimonRichardson thank you for the tip. As long as the suspect has been found there is no further question :)