From 8e5afdb546d331942e88c71f584c923c88a7f19c Mon Sep 17 00:00:00 2001 From: Alan Malta Rodrigues Date: Thu, 17 Aug 2023 17:00:59 -0400 Subject: [PATCH] Empty list should return None as well --- src/python/WMCore/BossAir/Plugins/BasePlugin.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/python/WMCore/BossAir/Plugins/BasePlugin.py b/src/python/WMCore/BossAir/Plugins/BasePlugin.py index a513a59d0f1..9a1b77df477 100644 --- a/src/python/WMCore/BossAir/Plugins/BasePlugin.py +++ b/src/python/WMCore/BossAir/Plugins/BasePlugin.py @@ -196,7 +196,7 @@ def cudaCapabilityToSingleVersion(capabilities=None): For further details: https://docs.nvidia.com/cuda/cuda-runtime-api/group__CUDART____VERSION.html """ - if not isinstance(capabilities, list): + if not (isinstance(capabilities, list) and capabilities): return None # now order the list of string versions in place. Precedence of digits is from left to right # from: ["2.3.1", "1.2.3", "3.2.1", "1.3.2"]