dns-ha - code not compatible with python3-yaml from jammy/antelope
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
OpenStack HA Cluster Charm |
New
|
Undecided
|
Unassigned |
Bug Description
MAAS DNS driver is using yaml library from OS. In case of running the charm on node with jammy/antelope repository the python3-yaml is in 6.0 version. In that version yaml.load requires mandatory Loader argument (https:/
This can be fixed by either adding the Loader or replacing the method like below:
--- /usr/lib/
+++ apidriver_safe.py
@@ -91,7 +91,7 @@
code = response.getcode()
if code == OK:
- return Response(True, yaml.load(payload), code)
+ return Response(True, yaml.safe_
else:
return Response(False, payload, code)
@@ -107,7 +107,7 @@
code = response.getcode()
if code == OK:
- return Response(True, yaml.load(payload), code)
+ return Response(True, yaml.safe_
else:
except HTTPError as e: