summaryrefslogtreecommitdiff
path: root/ironic_python_agent/errors.py
diff options
context:
space:
mode:
authorJay Faulkner <jay@jvf.cc>2015-02-11 14:20:02 -0800
committerJim Rollenhagen <jim@jimrollenhagen.com>2015-02-12 07:35:11 -0800
commite5d88be8cb98298323b4644dff08b38fc970f1cd (patch)
treec0cef4ef4761d1575d36f0b1e69b7eea5816cadb /ironic_python_agent/errors.py
parent6881726cb771aa966afa92498c8616ec5d0b5862 (diff)
downloadironic-python-agent-e5d88be8cb98298323b4644dff08b38fc970f1cd.tar.gz
Log required troubleshooting info on image dl fail
Currently, we only log the image ID and attempted URL. Now, we log the status code recieved and detailed information about how and when things failed. Change-Id: I718c7facbe1500d98be78b7b6137e92fdfb2fdf1 Closes-bug: 1420981 Depends-On: I69f6f6eef4ad573f406d64d579a9811c70ac5d28
Diffstat (limited to 'ironic_python_agent/errors.py')
-rw-r--r--ironic_python_agent/errors.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/ironic_python_agent/errors.py b/ironic_python_agent/errors.py
index 5ec2e3bf..f21678d4 100644
--- a/ironic_python_agent/errors.py
+++ b/ironic_python_agent/errors.py
@@ -137,8 +137,8 @@ class ImageDownloadError(RESTError):
message = 'Error downloading image.'
- def __init__(self, image_id):
- details = 'Could not download image with id {0}.'.format(image_id)
+ def __init__(self, image_id, msg):
+ details = 'Download of image id {0} failed: {1}'.format(image_id, msg)
super(ImageDownloadError, self).__init__(details)