Error after upgrading to revision 5, can't downgrade to revision 4

Bug #1991518 reported by Przemyslaw Lal
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
charm-cloudsupport
New
Undecided
Unassigned

Bug Description

After upgrading cloudsupport from revision 4 to 5, the unit ended up in the error/idle state, with the following error:

Traceback (most recent call last):
  File "./src/charm.py", line 8, in <module>
    from lib_cloudsupport import CloudSupportHelper
  File "/var/lib/juju/agents/unit-cloudsupport-0/charm/lib/lib_cloudsupport.py", line 16, in <module>
    from openstack.exceptions import SDKException
  File "/var/lib/juju/agents/unit-cloudsupport-0/charm/venv/openstack/__init__.py", line 17, in <module>
    import openstack.config
  File "/var/lib/juju/agents/unit-cloudsupport-0/charm/venv/openstack/config/__init__.py", line 17, in <module>
    from openstack.config.loader import OpenStackConfig # noqa
  File "/var/lib/juju/agents/unit-cloudsupport-0/charm/venv/openstack/config/loader.py", line 28, in <module>
    from keystoneauth1 import adapter
  File "/var/lib/juju/agents/unit-cloudsupport-0/charm/venv/keystoneauth1/__init__.py", line 16, in <module>
    __version__ = pbr.version.VersionInfo('keystoneauth1').version_string()
  File "/var/lib/juju/agents/unit-cloudsupport-0/charm/venv/pbr/version.py", line 500, in version_string
    return self.semantic_version().brief_string()
  File "/var/lib/juju/agents/unit-cloudsupport-0/charm/venv/pbr/version.py", line 493, in semantic_version
    self._semantic = self._get_version_from_importlib_metadata()
  File "/var/lib/juju/agents/unit-cloudsupport-0/charm/venv/pbr/version.py", line 478, in _get_version_from_importlib_metadata
    return SemanticVersion.from_pip_string(result_string)
  File "/var/lib/juju/agents/unit-cloudsupport-0/charm/venv/pbr/version.py", line 151, in from_pip_string
    return klass._from_pip_string_unsafe(version_string)
  File "/var/lib/juju/agents/unit-cloudsupport-0/charm/venv/pbr/version.py", line 158, in _from_pip_string_unsafe
    version_string = version_string.lstrip('vV')
AttributeError: 'NoneType' object has no attribute 'lstrip'

I couldn't find any workaround for this issue yet. Also, the charm can't be downgraded to v4 because of the following issue:

$ juju upgrade-charm --switch ch:cloudsupport-4 cloudsupport --channel latest/edge
Added charm-hub charm "cloudsupport", revision 4 in channel edge, to the model
ERROR cannot downgrade from v2 charm format to v1

Revision history for this message
Przemyslaw Lal (przemeklal) wrote :

Versions:

$ cat /etc/os-release
NAME="Ubuntu"
VERSION="20.04.4 LTS (Focal Fossa)"
ID=ubuntu
ID_LIKE=debian
PRETTY_NAME="Ubuntu 20.04.4 LTS"
VERSION_ID="20.04"
HOME_URL="https://www.ubuntu.com/"
SUPPORT_URL="https://help.ubuntu.com/"
BUG_REPORT_URL="https://bugs.launchpad.net/ubuntu/"
PRIVACY_POLICY_URL="https://www.ubuntu.com/legal/terms-and-policies/privacy-policy"
VERSION_CODENAME=focal
UBUNTU_CODENAME=focal

$ dpkg -l | grep openstack
ii python3-openstackclient 5.2.0-0ubuntu1 all OpenStack Command-line Client - Python 3.x
ii python3-openstacksdk 0.46.0-0ubuntu1 all SDK for building applications to work with OpenStack - Python 3.x

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.