This only happens in CI and I can't replicate this locally, but when upgrading a charm, we run into a "resolver loop error" for a machine.
$ juju --show-log bootstrap --constraints mem=2G lxd/localhost nw-deploy-lxd-profile-lxd --config /tmp/tmp0rhnFu.yaml --default-model nw-deploy-lxd-profile-lxd --agent-version 2.6-beta1
$ juju --show-log deploy -m nw-deploy-lxd-profile-lxd:nw-deploy-lxd-profile-lxd /var/lib/jenkins/workspace/nw-deploy-lxd-profile-lxd/acceptancetests//repository/charms/lxd-profile
$ juju --show-log deploy -m nw-deploy-lxd-profile-lxd:nw-deploy-lxd-profile-lxd /var/lib/jenkins/workspace/nw-deploy-lxd-profile-lxd/acceptancetests//repository/charms/lxd-profile-subordinate
$ juju --show-log add-relation -m nw-deploy-lxd-profile-lxd:nw-deploy-lxd-profile-lxd lxd-profile lxd-profile-subordinate
$ juju --show-log upgrade-charm -m nw-deploy-lxd-profile-lxd:nw-deploy-lxd-profile-lxd lxd-profile --path /var/lib/jenkins/workspace/nw-deploy-lxd-profile-lxd/acceptancetests//repository/charms/lxd-profile
$ juju --show-log upgrade-charm -m nw-deploy-lxd-profile-lxd:nw-deploy-lxd-profile-lxd lxd-profile-subordinate --path /var/lib/jenkins/workspace/nw-deploy-lxd-profile-lxd/acceptancetests//repository/charms/lxd-profile-subordinate
$ juju --show-log deploy -m nw-deploy-lxd-profile-lxd:nw-deploy-lxd-profile-lxd
/var/lib/jenkins/workspace/nw-deploy-lxd-profile-lxd/acceptancetests//repository/charms/ubuntu
$ juju --show-log add-relation -m nw-deploy-lxd-profile-lxd:nw-deploy-lxd-profile-lxd ubuntu lxd-profile-subordinate
$ juju --show-log upgrade-charm -m nw-deploy-lxd-profile-lxd:nw-deploy-lxd-profile-lxd ubuntu --path /var/lib/jenkins/workspace/nw-deploy-lxd-profile-lxd/acceptancetests//repository/charms/ubuntu
---
2019-03-29 02:10:14 ERROR ('lxd-profile/0', 'resolver loop error')
Traceback (most recent call last):
File "/var/lib/jenkins/workspace/nw-deploy-lxd-profile-lxd/acceptancetests/utility.py", line 416, in logged_exception
yield
File "/var/lib/jenkins/workspace/nw-deploy-lxd-profile-lxd/acceptancetests/deploy_stack.py", line 1022, in runtime_context
yield
File "/var/lib/jenkins/workspace/nw-deploy-lxd-profile-lxd/acceptancetests/deploy_stack.py", line 1143, in new_bootstrap
yield machines
File "/var/lib/jenkins/workspace/nw-deploy-lxd-profile-lxd/acceptancetests/deploy_stack.py", line 1124, in booted_context
yield machines
File "/var/lib/jenkins/workspace/nw-deploy-lxd-profile-lxd/acceptancetests//assess_deploy_lxd_profile.py", line 140, in main
assess_juju_lxdprofile_machine_upgrade(client, charm_ubuntu, False,"0", charm_profile_subordinate)
File "/var/lib/jenkins/workspace/nw-deploy-lxd-profile-lxd/acceptancetests//assess_deploy_lxd_profile.py", line 73, in assess_juju_lxdprofile_machine_upgrade
client.wait_for(AgentsIdle([charm_principal+"/"+unit_num]))
File "/var/lib/jenkins/workspace/nw-deploy-lxd-profile-lxd/acceptancetests/jujupy/client.py", line 1704, in wait_for
status.raise_highest_error(ignore_recoverable=False)
File "/var/lib/jenkins/workspace/nw-deploy-lxd-profile-lxd/acceptancetests/jujupy/status.py", line 356, in raise_highest_error
raise errors[0]
AgentError: ('lxd-profile/0', 'resolver loop error')
[Expired for juju because there has been no activity for 60 days.]