From c02b0727e98f4346333adc108753154c8d382408 Mon Sep 17 00:00:00 2001 From: Jan-Simon Moeller Date: Wed, 23 Sep 2020 14:34:45 +0200 Subject: Simplify uniqid Just use a random number. Fixes: Traceback (most recent call last): File /w/workspace/ci-apps-agl-service-bluetooth-verify-master-CIBT-x86-64/repoclone/releng-scripts/utils/create-jobs.py, line 126, in main() File /w/workspace/ci-apps-agl-service-bluetooth-verify-master-CIBT-x86-64/repoclone/releng-scripts/utils/create-jobs.py, line 110, in main app_changeid=args.app_changeid, app_patchset=args.app_patchset, app_branch=args.app_branch) File /w/workspace/ci-apps-agl-service-bluetooth-verify-master-CIBT-x86-64/repoclone/releng-scripts/utils/agljobtemplate.py, line 113, in render_job job[uniqid] = AGL-%s-%s-%s-%d % (machine, branch, version, random.randint(1, 999999)) Signed-off-by: Jan-Simon Moeller Change-Id: Ifef2d5831b37e69bef30f1d32730736dfafc5a57 (cherry picked from commit 6445b9a054c06648d6e09762749ee48b00e6e936) --- utils/agljobtemplate.py | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) (limited to 'utils') diff --git a/utils/agljobtemplate.py b/utils/agljobtemplate.py index a375da1..1003823 100644 --- a/utils/agljobtemplate.py +++ b/utils/agljobtemplate.py @@ -106,11 +106,7 @@ class Agljobtemplate(object): job['priority'] = priority job['build_type'] = build_type job['image_type'] = "AGL-%s" % build_type - - if patchset != None: - job["uniqid"] = "AGL-%s-%s-%s-%d" % (machine, changeid, patchset, random.randint(1, 999999)) - else: - job["uniqid"] = "AGL-%s-%s-%s-%d" % (machine, branch, version, random.randint(1, 999999)) + job["uniqid"] = "AGL-%s-%d" % (machine, random.randint(1, 999999)) defaults, infra = parse_cfg_file(self._template_path, 'default.cfg', build_type) -- cgit 1.2.3-korg