Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/actions/setup/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ description: Installs the given GardenLinux Python library
inputs:
version:
description: GardenLinux Python library version
default: "1.0.0"
default: "1.0.1"
python_version:
description: Python version to setup
default: "3.14"
Expand Down
1,699 changes: 863 additions & 836 deletions poetry.lock

Large diffs are not rendered by default.

23 changes: 12 additions & 11 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[tool.poetry]
name = "gardenlinux"
version = "1.0.0"
version = "1.0.1"
description = "Contains tools to work with the features directory of gardenlinux, for example deducting dependencies from feature sets or validating cnames"
authors = ["Garden Linux Maintainers <contact@gardenlinux.io>"]
license = "Apache-2.0"
Expand All @@ -10,31 +10,32 @@ packages = [{ include = "gardenlinux", from = "src" }]
[tool.poetry.dependencies]
python = ">=3.13,!=3.14.1"
apt-repo = "^0.5"
boto3 = "^1.43.108"
boto3 = "^1.44.2"
cryptography = "^49.0.0"
jsonschema = "^4.26.0"
networkx = "^3.7"
oras = "^0.2.43"
podman = "^5.8.0"
pygit2 = "^1.20.1"
pygit2 = "^1.21.0"
pygments = "^2.21.0"
PyGithub = "^2.10.0"
PyYAML = "^6.0.3"
semver = "^3.1.0"
semver = "^3.1.1"

[tool.poetry.group.dev.dependencies]
bandit = "^1.9.4"
boto3-stubs = { extras = ["s3"], version = "^1.44.2" }
isort = "^8.0.1"
moto = "^5.2.1"
pre-commit = "^4.6.2"
moto = "^5.2.5"
mypy = "2.1.0"
pre-commit = "^4.7.0"
python-dotenv = "^1.2.2"
pytest = "^9.1.1"
pytest = "^9.2.0"
pytest-cov = "^7.1.0"
requests-mock = "^1.12.1"
mypy = "2.1.0"
types-pyyaml = "^6.0.12.20260518"
types-requests = "^2.33.0.20260518"
boto3-stubs = { extras = ["s3"], version = "^1.42.41" }
sphinx = "9.2.0"
types-pyyaml = "^6.0.12.20261111"
types-requests = "^2.33.0.20261030"

[tool.poetry.group.docs.dependencies]
sphinx-rtd-theme = "^3.1.0"
Expand Down
2 changes: 1 addition & 1 deletion src/gardenlinux/features/artifact_base_name.py
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ def __init__(
"""

re_object = re.compile(
"([a-zA-Z0-9]+([\\_\\-][a-zA-Z0-9]+)*?)-([a-z0-9]+)-([a-z0-9.]+)-([a-z0-9]+)(\\.|$)"
"([a-zA-Z0-9]+([\\_\\-][a-zA-Z0-9]+)*?)-([a-z0-9]+)-([a-z0-9.]+)-([a-z0-9]+)$"
)

re_match = re_object.match(artifact)
Expand Down
2 changes: 1 addition & 1 deletion src/gardenlinux/oci/repository.py
Original file line number Diff line number Diff line change
Expand Up @@ -577,7 +577,7 @@ def push_oci_archive(
if not oci_image_ref_name:
oci_image_ref_name = None

with TemporaryDirectory(delete=False) as tmpdir:
with TemporaryDirectory() as tmpdir:
tar_file = TarFile.taropen(oci_archive_file_name)
tar_file.extractall(tmpdir)

Expand Down
12 changes: 8 additions & 4 deletions tests/features/test_main.py
Original file line number Diff line number Diff line change
Expand Up @@ -46,18 +46,22 @@ class MockGraph:
def test_get_version_and_commit_from_file(tmp_path: Path) -> None:
# Arrange
commit_file = tmp_path / "COMMIT"
commit_file.write_text("abcdef12\n")

commit_file.write_text(
"2e8f62e0560b2c3913f4d9aaf3b3d9f1cdc8b79c1929d5026ca6f053969a4a24\n"
)

version_file = tmp_path / "VERSION"
version_file.write_text("1.2.3\n")
version_file.write_text("42.0.0\n")

# Act
version, commit = ArtifactBaseName.get_version_and_commit_id_from_files(
str(tmp_path)
)

# Arrange
assert version == "1.2.3"
assert commit == "abcdef12"
assert version == "42.0.0"
assert commit == "2e8f62e0"


# -------------------------------
Expand Down
Loading