Closed fnordahl closed 1 month ago
This simple patch appears to fix it, but I'm sure we would be able to get the version information hiding behind devel
to perform proper validation:
diff --git a/charmcraft/bases.py b/charmcraft/bases.py
index c5b362e..297a8ac 100644
--- a/charmcraft/bases.py
+++ b/charmcraft/bases.py
@@ -58,7 +58,7 @@ def check_if_base_matches_host(base: Base) -> Tuple[bool, Union[str, None]]:
host_channel = host_base.channel
else:
host_channel = host_base.channel.split(".")[0]
- if host_channel != base.channel:
+ if base.channel != "devel" and host_channel != base.channel:
return (
False,
f"channel {base.channel!r} does not match host {host_base.channel!r}",
I believe this is fixed in Charmcraft 3. If not, please reopen :-)
Bug Description
Slightly, but not quite, related to #1104 and #1203.
As proponents and developers of model driven operations, trying to release machine charms for new versions of, ehh, machines, it would be great to be able to know ahead of time whether your charmed machine operator would work with the next Ubuntu release.
The references above and this bug report serves as proof that this is not currently possible.
To Reproduce
Attempt to pack a charm with a bases config like:
Environment
N/A
charmcraft.yaml
Relevant log output