python3Packages.craft-providers: 2.3.1 -> 2.4.0

This commit is contained in:
Jon Seager
2025-07-22 13:39:23 +02:00
parent 0ffe69f856
commit 7356bc8e16
2 changed files with 16 additions and 11 deletions
@@ -21,7 +21,7 @@
buildPythonPackage rec {
pname = "craft-providers";
version = "2.3.1";
version = "2.4.0";
pyproject = true;
@@ -29,7 +29,7 @@ buildPythonPackage rec {
owner = "canonical";
repo = "craft-providers";
tag = version;
hash = "sha256-MeQOqw0F4OwaooHHrUh3qITTOFNXG1Qg1oJcYxRQTz0=";
hash = "sha256-frcRv+19czsZ948SEKfYsMUP6n9MbJv6gxXUAdwFw4Y=";
};
patches = [
@@ -51,7 +51,7 @@ buildPythonPackage rec {
# The urllib3 incompat: https://github.com/msabramo/requests-unixsocket/pull/69
# This is already patched in nixpkgs.
substituteInPlace pyproject.toml \
--replace-fail "setuptools==75.2.0" "setuptools"
--replace-fail "setuptools==75.9.1" "setuptools"
'';
pythonRelaxDeps = [ "requests" ];
@@ -1,8 +1,8 @@
diff --git a/craft_providers/base.py b/craft_providers/base.py
index 3c914a2..d9c2cf9 100644
--- a/craft_providers/base.py
+++ b/craft_providers/base.py
@@ -655,37 +655,22 @@ class Base(ABC):
diff --git i/craft_providers/base.py w/craft_providers/base.py
index 00f56ec..302f359 100644
--- i/craft_providers/base.py
+++ w/craft_providers/base.py
@@ -655,40 +655,24 @@ class Base(ABC):
),
)
@@ -21,6 +21,9 @@ index 3c914a2..d9c2cf9 100644
- f" channel {snap.channel!r} in target environment."
- ),
- details=error.details,
- resolution=(
- "Check Snap store status at https://status.snapcraft.io"
- ),
- ) from error
- else:
- try:
@@ -38,20 +41,22 @@ index 3c914a2..d9c2cf9 100644
- details=error.details,
- ) from error
+ try:
+ channel = "latest/beta"
+ snap_installer.install_from_store(
+ executor=executor,
+ snap_name=snap.name,
+ channel=channel,
+ channel=snap.channel,
+ classic=snap.classic,
+ )
+ except SnapInstallationError as error:
+ raise BaseConfigurationError(
+ brief=(
+ f"failed to install snap {snap.name!r} from store"
+ f" channel {channel!r} in target environment."
+ f" channel {snap.channel!r} in target environment."
+ ),
+ details=error.details,
+ resolution=(
+ "Check Snap store status at https://status.snapcraft.io"
+ ),
+ ) from error
def wait_until_ready(self, executor: Executor) -> None: