diff --git a/Phonak Target Media Checker.py b/Phonak Target Media Checker.py index fe6e206..a8dd79e 100644 --- a/Phonak Target Media Checker.py +++ b/Phonak Target Media Checker.py @@ -49,10 +49,15 @@ updaterRetries = libhearingdownloader.updaterRetries while updaterRetries > 0: try: - hostXmlData = requests.get("https://p-svc1.phonakpro.com/1/ObjectLocationService.svc/FittingApplicationInstaller/index?appName=Phonak%20Target&appVer=6.0.1.695&dist=Phonak&country=US&subKeys=").text # Request the updater API (spoof older version to get whole installer files rather than "patch" installers) + hostXmlData = requests.get("https://p-svc1.phonakpro.com/1/ObjectLocationService.svc/FittingApplicationInstaller/index?appName=Phonak%20Target&appVer=6.0.1.695&dist=Phonak&country=GB&subKeys=").text # Request the updater API (spoof older version to get whole installer files rather than "patch" installers) hostData = xml.fromstring(hostXmlData) hostAppVer = hostData[0].find(xmlns + "UpdateVersion").find(xmlns + "Version").text xmlData = requests.get("https://p-svc1.phonakpro.com/1/ObjectLocationService.svc/MediaInstaller/index?appName=Target%20Media&appVer=0.0.0.0;" + hostAppVer + "&dist=Phonak&country=GB&subKeys=").text # Request the updater API with the latest version number of Phonak Target + if (xmlData == ''): + hostXmlData = requests.get("https://p-svc1.phonakpro.com/1/ObjectLocationService.svc/FittingApplicationInstaller/index?appName=Phonak%20Target&appVer=6.0.1.695&dist=Phonak&country=US&subKeys=").text # Request the updater API (spoof older version to get whole installer files rather than "patch" installers) + hostData = xml.fromstring(hostXmlData) + hostAppVer = hostData[0].find(xmlns + "UpdateVersion").find(xmlns + "Version").text + xmlData = requests.get("https://p-svc1.phonakpro.com/1/ObjectLocationService.svc/MediaInstaller/index?appName=Target%20Media&appVer=0.0.0.0;" + hostAppVer + "&dist=Phonak&country=US&subKeys=").text # Request the updater API with the latest version number of Phonak Target data = xml.fromstring(xmlData) break except: diff --git a/README.md b/README.md index 74787c3..189e964 100644 --- a/README.md +++ b/README.md @@ -84,8 +84,9 @@ NOTE: If you run The Checker (on Windows OS) without Python installed yet, The C - [@tenkan](https://forum.hearingtracker.com/u/tenkan/summary): Finding the Genie (2) download page links ## Changelog -### Pre-release (work-in-progress) -- Phonak: workaround for Target 10.0.1 seems not available in US market +### v2024.12.22 +- Phonak: fix Target checker for v10.0.1 +- Phonak: failsafe for Target Media checker - Document (README) update ### v2024.12.06 diff --git a/libhearingdownloader.py b/libhearingdownloader.py index ecfeccb..20d9fbc 100644 --- a/libhearingdownloader.py +++ b/libhearingdownloader.py @@ -27,8 +27,8 @@ # libhearingdownloader - A useful library for the downloader scripts ### -downloaderVersion = "Pre-release" -#downloaderVersion = "v2024.12.06" +#downloaderVersion = "Pre-release" +downloaderVersion = "v2024.12.22" updaterRetries = 3 verboseDebug = False