From 3f4a23645db4517c57f541e4aa178374d9761f84 Mon Sep 17 00:00:00 2001 From: pedro Date: Thu, 10 Oct 2024 19:09:44 +0200 Subject: [PATCH] allow more response codes --- workbench-script.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/workbench-script.py b/workbench-script.py index 6218b39..867ef07 100644 --- a/workbench-script.py +++ b/workbench-script.py @@ -303,7 +303,7 @@ def send_snapshot_to_devicehub(snapshot, token, url): } try: response = requests.post(url, data=json.dumps(snapshot), headers=headers) - if response.status_code == 200: + if 200 <= response.status_code < 300: print(f"workbench: INFO: Snapshot successfully sent to '{url}'") else: txt = "workbench: ERROR: Failed to send snapshot. HTTP {}: {}".format(