From 1ce2492256af256e1076f0e88402e8e1d8a271f2 Mon Sep 17 00:00:00 2001 From: Sam Thursfield Date: Wed, 11 Feb 2015 12:41:27 +0000 Subject: distbuild: Give more detail when requests to cache-server fail Let the end-user see the URL that distbuild was attempting to talk to, so they can more easily spot configuration errors. It's kind of silly to say 'HTTP request failed' without saying where the request was going. --- distbuild/build_controller.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/distbuild/build_controller.py b/distbuild/build_controller.py index aeeda417..6752f400 100644 --- a/distbuild/build_controller.py +++ b/distbuild/build_controller.py @@ -361,8 +361,9 @@ class BuildController(distbuild.StateMachine): http_status_code = event.msg['status'] if http_status_code != httplib.OK: - self.fail('Failed to annotate build graph: http request got %d: %s' - % (http_status_code, event.msg['body'])) + self.fail('Failed to annotate build graph: HTTP request to %s got ' + '%d: %s' % (self._artifact_cache_server, + http_status_code, event.msg['body'])) return cache_state = json.loads(event.msg['body']) -- cgit v1.2.1