From ed041e026dc51e7d5598332880c543c5afbc5884 Mon Sep 17 00:00:00 2001 From: Nayil Mukhametshin <66028747+nlscc@users.noreply.github.com> Date: Sat, 1 Aug 2020 14:18:04 +0100 Subject: add better error handling to checkupdate --- samloader/versionfetch.py | 1 + 1 file changed, 1 insertion(+) diff --git a/samloader/versionfetch.py b/samloader/versionfetch.py index a9d2437..800a297 100644 --- a/samloader/versionfetch.py +++ b/samloader/versionfetch.py @@ -8,6 +8,7 @@ import requests def getlatestver(region, model): r = requests.get("http://fota-cloud-dn.ospserver.net/firmware/" + region + "/" + model + "/version.xml") + r.raise_for_status() root = ET.fromstring(r.text) vercode = root.find("./firmware/version/latest").text vc = vercode.split("/") -- cgit v1.2.3