From 84f7766dcf1717c98a4ab0000f94bd916209faf8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lubom=C3=ADr=20Sedl=C3=A1=C5=99?= Date: Thu, 24 Jul 2025 13:34:44 +0200 Subject: [PATCH] Add a tracing span around call to skopeo inspect MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This call can fail and with a span we can get better visibility into that. Signed-off-by: Lubomír Sedlář (cherry picked from commit 7b803d620f9951ef4ee1a17eeb5e46b8c9728e47) --- pungi/util.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/pungi/util.py b/pungi/util.py index eb468212..c47a2796 100644 --- a/pungi/util.py +++ b/pungi/util.py @@ -276,7 +276,8 @@ class ContainerTagResolver(object): raise RuntimeError("Failed to find tag name") tag = m.group(1) - data = _skopeo_inspect(url) + with tracing.span("skopeo-inspect", url=url): + data = _skopeo_inspect(url) digest = data["Digest"] return url.replace(tag, f"@{digest}") @@ -1075,7 +1076,7 @@ def format_size(sz): return "%.3g %sB" % (sz, UNITS[unit]) -@retry(interval=60, timeout=300, wait_on=RuntimeError) +@retry(interval=5, timeout=60, wait_on=RuntimeError) def _skopeo_inspect(url): """Wrapper for running `skopeo inspect {url}` and parsing the output. Retries on failure.