From cb53de3c46072a2abbcf16ffd5abded4fefbd413 Mon Sep 17 00:00:00 2001 From: Stepan Oksanichenko Date: Fri, 6 Sep 2024 22:28:38 +0300 Subject: [PATCH] - Truncate a volume ID to 32 bytes - Add new architecture `x86_64_v2` --- pungi/arch_utils.py | 2 ++ pungi/util.py | 5 +---- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/pungi/arch_utils.py b/pungi/arch_utils.py index d01eccd2..fbb45c32 100644 --- a/pungi/arch_utils.py +++ b/pungi/arch_utils.py @@ -34,6 +34,8 @@ arches = { "x86_64": "athlon", "amd64": "x86_64", "ia32e": "x86_64", + # x86-64-v2 + "x86_64_v2": "noarch", # ppc64le "ppc64le": "noarch", # ppc diff --git a/pungi/util.py b/pungi/util.py index bf2a3cac..4ed9758b 100644 --- a/pungi/util.py +++ b/pungi/util.py @@ -487,10 +487,7 @@ def get_volid(compose, arch, variant=None, disc_type=False, formats=None, **kwar tried.add(volid) if volid and len(volid) > 32: - raise ValueError( - "Could not create volume ID longer than 32 bytes, options are %r", - sorted(tried, key=len), - ) + volid = volid[:32] if compose.conf["restricted_volid"]: # Replace all non-alphanumeric characters and non-underscores) with