Skip to contentSkip to conversation

scheduler: make the default choice an option

PATCH New Michael Halstead 1 participant 1 message Oct 18, 2019

lore
Share & tools
lore
#0 lore raw

PATCH v2 1/1 scheduler: make the default choice an option

The default choice on the force build form will select a random worker.

builder_to_workers dictionary values can no longer be strings.

---
 config.py     | 4 ++--
 schedulers.py | 2 +-
 2 files changed, 3 insertions(+), 3 deletions(-)
config.py +2 -2
index e9d6d98..1577bcf 100644
@@ -127,7 +127,7 @@ builder_to_workers = {
     "oe-selftest-opensuse": workers_opensuse,
     "oe-selftest-centos": workers_centos,
     "meta-mingw": workers_wine,
-    "buildperf-ubuntu1604": "perf-ubuntu1604",
-    "buildperf-centos7": "perf-centos7",
+    "buildperf-ubuntu1604": ["perf-ubuntu1604"],
+    "buildperf-centos7": ["perf-centos7"],
     "default": workers
 }
schedulers.py +1 -1
index b22f18f..671baae 100644
@@ -81,7 +81,7 @@ def props_for_builder(builder):
                               default="*",
                               multiple=False,
                               strict=True,
-                              choices=worker_list))
+                              choices=worker_list + ["*"]))
     return props
 
 
Signature · 1 line
2.21.0