From aab00a24e351607fe9c046798cac175403b6e0ca Mon Sep 17 00:00:00 2001 From: Angel Luis Blasco <22562761+alblasco@users.noreply.github.com> Date: Mon, 5 Aug 2024 17:00:27 +0200 Subject: [PATCH] Fix exception in case no hostname label is available --- sdcclient/_common.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sdcclient/_common.py b/sdcclient/_common.py index e565168a..72897411 100644 --- a/sdcclient/_common.py +++ b/sdcclient/_common.py @@ -509,7 +509,7 @@ def create_sysdig_capture(self, hostname, capture_name, duration, capture_filter capture_agent = None for agent in res[1]: - if hostname == agent['hostName']: + if hostname == agent.get('hostName'): capture_agent = agent break