juju / charm-helpers

Apache License 2.0
18 stars 127 forks source link

Improve detection of debian systems #865

Closed samuelallan72 closed 10 months ago

samuelallan72 commented 10 months ago

It appears, from reading osplatform.py, that Debian should be supported, however, it's been observed in python3.11 on debian bookworm, that it raises an error about no debian support (in a zuul test run):

debian-bookworm |   File "/home/zuul/src/opendev.org/openstack/charm-ceph-iscsi/.tox/py311/lib/python3.11/site-packages/charmhelpers/osplatform.py", line 35, in get_platform
debian-bookworm |     raise RuntimeError("This module is not supported on {}."
debian-bookworm | RuntimeError: This module is not supported on Debian GNU/Linux.

Improve detection by comparing in a case insensitive manner.

Fixes bug https://bugs.launchpad.net/charm-helpers/+bug/2040958

samuelallan72 commented 10 months ago

Note: on pause, pending discussion over at #862