From 00634fce3d38eb1f035997d458de388940a71b55 Mon Sep 17 00:00:00 2001 From: Michael William Boldt Date: Wed, 19 Oct 2016 15:05:38 -0500 Subject: [PATCH] Print URL of failed request. --- tile_generator/opsmgr.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tile_generator/opsmgr.py b/tile_generator/opsmgr.py index 81efba92..dfcfd117 100644 --- a/tile_generator/opsmgr.py +++ b/tile_generator/opsmgr.py @@ -137,7 +137,7 @@ def delete(url, check=True): def check_response(response, check=True): if check and response.status_code != requests.codes.ok: - print('-', response.status_code, file=sys.stderr) + print('-', response.status_code, response.request.url, file=sys.stderr) try: errors = response.json()["errors"] print('- '+('\n- '.join(json.dumps(errors, indent=4).splitlines())), file=sys.stderr)