From 02c5914d29a8706cadc22317f8b5abd1630ce373 Mon Sep 17 00:00:00 2001 From: Alfred Landrum Date: Thu, 4 May 2017 16:22:15 -0700 Subject: [PATCH] Update image create error parsing Support new error message returned for image creation in: https://github.com/moby/moby/pull/33005 Signed-off-by: Alfred Landrum --- docker/errors.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/docker/errors.py b/docker/errors.py index 03b89c11e3..0da97f4e3f 100644 --- a/docker/errors.py +++ b/docker/errors.py @@ -23,7 +23,8 @@ def create_api_error_from_http_exception(e): if response.status_code == 404: if explanation and ('No such image' in str(explanation) or 'not found: does not exist or no pull access' - in str(explanation)): + in str(explanation) or + 'repository does not exist' in str(explanation)): cls = ImageNotFound else: cls = NotFound