]> git-server-git.apps.pok.os.sepia.ceph.com Git - teuthology.git/commitdiff
Add a warning when gitbuilder 404s 793/head
authorZack Cerza <zack@redhat.com>
Fri, 26 Feb 2016 00:59:51 +0000 (17:59 -0700)
committerZack Cerza <zack@redhat.com>
Fri, 26 Feb 2016 00:59:51 +0000 (17:59 -0700)
When determining the ceph hash, we usually ask gitbuilder. When that
fails, the error is misleading but it would take a bit of refactoring to
truly fix it. Let's at least put a useful warning before the confusing error
message.

Signed-off-by: Zack Cerza <zack@redhat.com>
teuthology/suite.py

index 66d17979e6cf714c288de920e30c4753d14143b7..87d924687239185357b4230bd2323d2ac4617bfd 100644 (file)
@@ -446,6 +446,16 @@ def get_hash(project='ceph', branch='master', flavor='basic',
     log.debug("Gitbuilder URL: %s", url)
     resp = requests.get(url)
     if not resp.ok:
+        msg = "Got a {0} trying to get hash for project '{1}' " + \
+            "and branch '{2}' from URL: {3}"
+        log.warn(
+            msg.format(
+                resp.status_code,
+                project,
+                branch,
+                url
+            )
+        )
         return None
     return str(resp.text.strip())