funcd-bundle 0.7.0__tar.gz → 0.8.1__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {funcd_bundle-0.7.0 → funcd_bundle-0.8.1}/PKG-INFO +1 -1
- {funcd_bundle-0.7.0 → funcd_bundle-0.8.1}/pyproject.toml +1 -1
- {funcd_bundle-0.7.0 → funcd_bundle-0.8.1}/src/funcd_bundle/bundle.py +12 -1
- {funcd_bundle-0.7.0 → funcd_bundle-0.8.1}/tests/test_bundle.py +7 -1
- {funcd_bundle-0.7.0 → funcd_bundle-0.8.1}/.gitignore +0 -0
- {funcd_bundle-0.7.0 → funcd_bundle-0.8.1}/README.md +0 -0
- {funcd_bundle-0.7.0 → funcd_bundle-0.8.1}/src/funcd_bundle/__init__.py +0 -0
- {funcd_bundle-0.7.0 → funcd_bundle-0.8.1}/src/funcd_bundle/cli.py +0 -0
- {funcd_bundle-0.7.0 → funcd_bundle-0.8.1}/uv.lock +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.5
|
|
2
2
|
Name: funcd-bundle
|
|
3
|
-
Version: 0.
|
|
3
|
+
Version: 0.8.1
|
|
4
4
|
Summary: Bundle a Python funcd function and its locked dependencies for the funcd runtime
|
|
5
5
|
Project-URL: Homepage, https://github.com/pyvvo/funcd-python
|
|
6
6
|
Project-URL: Repository, https://github.com/pyvvo/funcd-python
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
[project]
|
|
2
2
|
name = "funcd-bundle"
|
|
3
3
|
# Not bumped per release: the vX.Y.Z git tag is the version, stamped into the build at publish time.
|
|
4
|
-
version = "0.
|
|
4
|
+
version = "0.8.1"
|
|
5
5
|
description = "Bundle a Python funcd function and its locked dependencies for the funcd runtime"
|
|
6
6
|
authors = [{ name = "The funcd Authors" }]
|
|
7
7
|
readme = "README.md"
|
|
@@ -28,6 +28,13 @@ from pathlib import Path
|
|
|
28
28
|
import yaml
|
|
29
29
|
|
|
30
30
|
BASE_IMAGE = "python:3.14-slim-bookworm"
|
|
31
|
+
# BASE_IMAGE pinned per platform (its index is sha256:48b13b00…0f83), so a bundle builds from one image on
|
|
32
|
+
# every machine. Not the index digest: the classic image store maps one digest to one image, so it cannot hold
|
|
33
|
+
# both platforms of an index under one digest. Move the three together.
|
|
34
|
+
BASE_IMAGES = {
|
|
35
|
+
"linux/amd64": "python@sha256:a66d3a463d0be3cc537c269b0d3418746dda512417a975559a0eaa8a6406baaf",
|
|
36
|
+
"linux/arm64": "python@sha256:0e24db28cf5b7788413afe3fdc63075ca22bc4ecf74f5472304b391c2110e629",
|
|
37
|
+
}
|
|
31
38
|
PYTHON_VERSION = "3.14"
|
|
32
39
|
GLIBC = "2_36"
|
|
33
40
|
MANIFEST_SUFFIX = ".funcdctl.yaml"
|
|
@@ -286,7 +293,11 @@ def _check(out: Path, platform: str, modules: list[str]) -> None:
|
|
|
286
293
|
|
|
287
294
|
|
|
288
295
|
def _create(platform: str, env: list[str], command: list[str]) -> str:
|
|
289
|
-
return
|
|
296
|
+
return (
|
|
297
|
+
_run(["docker", "create", "--platform", platform, *env, BASE_IMAGES[platform], *command])
|
|
298
|
+
.decode()
|
|
299
|
+
.strip()
|
|
300
|
+
)
|
|
290
301
|
|
|
291
302
|
|
|
292
303
|
def _start(cid: str, what: str) -> None:
|
|
@@ -19,7 +19,7 @@ import pytest
|
|
|
19
19
|
import yaml
|
|
20
20
|
|
|
21
21
|
from funcd_bundle import BundleError, bundle, discover, host_platform
|
|
22
|
-
from funcd_bundle.bundle import _check
|
|
22
|
+
from funcd_bundle.bundle import BASE_IMAGES, PLATFORMS, _check
|
|
23
23
|
from funcd_bundle.cli import main
|
|
24
24
|
|
|
25
25
|
FOREIGN = {"linux/arm64": "linux/amd64", "linux/amd64": "linux/arm64"}
|
|
@@ -362,3 +362,9 @@ def test_issue_r48_invalid_manifest_yaml_is_reported(
|
|
|
362
362
|
assert err.startswith(f"funcd-bundle: {tmp_path / 'funcdctl.yaml'}: "), err
|
|
363
363
|
assert "while parsing a flow node" in err, "the parser message names the problem"
|
|
364
364
|
assert "Traceback" not in err
|
|
365
|
+
|
|
366
|
+
|
|
367
|
+
def test_base_image_is_pinned_by_digest() -> None:
|
|
368
|
+
assert set(BASE_IMAGES) == set(PLATFORMS), "one pinned image per platform a bundle builds for"
|
|
369
|
+
for platform, ref in BASE_IMAGES.items():
|
|
370
|
+
assert re.fullmatch(r"python@sha256:[0-9a-f]{64}", ref), f"{platform}: {ref}"
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|