From 5a952b2392fe4dcf038de134058fa8e4627cfc83 Mon Sep 17 00:00:00 2001 From: peusterm Date: Thu, 27 Apr 2017 15:20:51 +0200 Subject: [PATCH] Fix: Dumb bug. This happens if your commit before testing locally :-) --- src/emuvim/api/sonata/dummygatekeeper.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/emuvim/api/sonata/dummygatekeeper.py b/src/emuvim/api/sonata/dummygatekeeper.py index b6d1dd7..813bc5e 100755 --- a/src/emuvim/api/sonata/dummygatekeeper.py +++ b/src/emuvim/api/sonata/dummygatekeeper.py @@ -272,9 +272,9 @@ class Service(object): # 3. get the resource limits res_req = u.get("resource_requirements") cpu_list = res_req.get("cpu").get("cores") - if not cpu_list or len(cpu_list)==0: + if cpu_list is None: cpu_list = res_req.get("cpu").get("vcpus") - if not cpu_list or len(cpu_list)==0: + if cpu_list is None: cpu_list="1" cpu_bw = res_req.get("cpu").get("cpu_bw") if not cpu_bw: -- 2.25.1