juju / juju-gui

Juju-GUI is a web-based GUI for Juju <https://jujucharms.com/>.
Other
182 stars 85 forks source link

exporting a modified bundle breaks relation data #3548

Closed mitechie closed 6 years ago

mitechie commented 6 years ago

I have my bundle cs:~rharding/bundle/gypsy-danger-testing-2

I add that to my model and it loads up in uncomitted state.

I then click on mysql and click destroy so that I do not have mysql as part of it any more. When I export it I properly have the lack of mysql in my applications but the relation is still there but replaced with a strange variable

  - - '90041383$:db'
    - 'gypsy-danger:db'
hatched commented 6 years ago

Thanks for the bug report @mitechie.

That strange variable, for who may be investigating, if it's not me, is the temporary id that is assigned to applications before they are deployed and we have a definite application id.

@mitechie could you please add the bundle yaml to this bug.

mitechie commented 6 years ago
series: xenial
applications: 
  mysql: 
    charm: "cs:mysql-57"
    num_units: 1
    annotations: 
      "gui-x": "700"
      "gui-y": "658.2050807568877"
  "gypsy-danger": 
    charm: "cs:~rharding/gypsy-danger-5"
    num_units: 1
    annotations: 
      "gui-x": "1100"
      "gui-y": "658.2050807568877"
  grafana: 
    charm: "cs:~rharding/grafana-3"
    num_units: 1
    options: 
      admin_password: testing
    expose: true
    annotations: 
      "gui-x": "900"
      "gui-y": "311.79491924311225"
relations: 
  - - "gypsy-danger:grafana-source"
    - "grafana:grafana-source"
  - - "mysql:db"
    - "gypsy-danger:db"
huwshimi commented 6 years ago

From what I can track down, when it deletes the uncomitted model, the app's relations property is empty.

Could it be something to do with this being a ghost app and somehow that stuff isn't being set up correctly?