← Back to team overview

canonical-ubuntu-qa team mailing list archive

[Merge] ~andersson123/autopkgtest-cloud:reduce-retries into autopkgtest-cloud:master

 

Tim Andersson has proposed merging ~andersson123/autopkgtest-cloud:reduce-retries into autopkgtest-cloud:master.

Requested reviews:
  Canonical's Ubuntu QA (canonical-ubuntu-qa)

For more details, see:
https://code.launchpad.net/~andersson123/autopkgtest-cloud/+git/autopkgtest-cloud/+merge/463031
-- 
Your team Canonical's Ubuntu QA is requested to review the proposed merge of ~andersson123/autopkgtest-cloud:reduce-retries into autopkgtest-cloud:master.
diff --git a/charms/focal/autopkgtest-cloud-worker/autopkgtest-cloud/worker/worker b/charms/focal/autopkgtest-cloud-worker/autopkgtest-cloud/worker/worker
index f1bbac5..9c4fc8d 100755
--- a/charms/focal/autopkgtest-cloud-worker/autopkgtest-cloud/worker/worker
+++ b/charms/focal/autopkgtest-cloud-worker/autopkgtest-cloud/worker/worker
@@ -1166,36 +1166,38 @@ def request(msg):
                     trigs = [
                         t.split("/", 1)[0] for t in params.get("triggers", [])
                     ]
-                    fail_trigs = [
-                        j
-                        for i in [
-                            getglob(FAIL_PKG_STRINGS, trig, [])
-                            for trig in trigs
-                        ]
-                        for j in i
-                    ]
+                    # fail_trigs = [
+                    #     j
+                    #     for i in [
+                    #         getglob(FAIL_PKG_STRINGS, trig, [])
+                    #         for trig in trigs
+                    #     ]
+                    #     for j in i
+                    # ]
 
                     # Or if all-proposed, just give up and accept everything
-                    fail_all_proposed = [
-                        j for i in FAIL_PKG_STRINGS.values() for j in i
-                    ]
+                    # fail_all_proposed = [
+                    #     j for i in FAIL_PKG_STRINGS.values() for j in i
+                    # ]
+
+                    # allowed_fail_strings = set(
+                    #     FAIL_STRINGS
+                    #     + getglob(FAIL_PKG_STRINGS, pkgname, [])
+                    #     + fail_trigs
+                    #     + (
+                    #         fail_all_proposed
+                    #         if "all-proposed" in params
+                    #         else []
+                    #     )
+                    # ) - set(getglob(OK_PKG_STRINGS, pkgname, []))
+
+                    # fails = [
+                    #     s for s in allowed_fail_strings if s in contents
+                    # ] + [
+                    #     s for s in FAIL_STRINGS_REGEX if re.search(s, contents)
+                    # ]
+                    fails = True
 
-                    allowed_fail_strings = set(
-                        FAIL_STRINGS
-                        + getglob(FAIL_PKG_STRINGS, pkgname, [])
-                        + fail_trigs
-                        + (
-                            fail_all_proposed
-                            if "all-proposed" in params
-                            else []
-                        )
-                    ) - set(getglob(OK_PKG_STRINGS, pkgname, []))
-
-                    fails = [
-                        s for s in allowed_fail_strings if s in contents
-                    ] + [
-                        s for s in FAIL_STRINGS_REGEX if re.search(s, contents)
-                    ]
                     if fails:
                         num_failures += 1
                         logging.warning(
@@ -1203,6 +1205,8 @@ def request(msg):
                             " and ".join(fails),
                             num_failures,
                         )
+                        # This is already cowboy'd in prod.
+                        retry = 3
                     logging.warning(
                         "Testbed failure. %sLog follows:", retrying
                     )