mirror of
https://github.com/f-droid/fdroidserver.git
synced 2025-11-06 07:20:29 +03:00
verify: if downloading from /repo/ fails, try /archive/
The Builds entries in metadata/ files do not easily say whether a given APK is in the repo/ or the archive/. So it should also try to download the official APK from the archive/ when verifying.
This commit is contained in:
parent
67d98c5a36
commit
7613c18dd8
1 changed files with 4 additions and 1 deletions
|
|
@ -79,6 +79,9 @@ def main():
|
||||||
logging.info("...retrieving " + url)
|
logging.info("...retrieving " + url)
|
||||||
try:
|
try:
|
||||||
net.download_file(url, dldir=tmp_dir)
|
net.download_file(url, dldir=tmp_dir)
|
||||||
|
except requests.exceptions.HTTPError as e:
|
||||||
|
try:
|
||||||
|
net.download_file(url.replace('/repo', '/archive/'), dldir=tmp_dir)
|
||||||
except requests.exceptions.HTTPError as e:
|
except requests.exceptions.HTTPError as e:
|
||||||
raise FDroidException('Downloading %s failed. %s', (url, e))
|
raise FDroidException('Downloading %s failed. %s', (url, e))
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue