forked from Mirror/pmbootstrap
Make APKINDEX downloads returning 404 non-fatal (!1726)
Do not fail when an APKINDEX can not be downloaded, print a WARNING instead. This matches, what apk does. Add a new allow_404 parameter to pmb.helpers.http.download(), and use it in pmb.helpers.repo.update() for downloading APKINDEX files. Cache the APKINDEX URLs that gave a 404 for the session, so we do not attempt to download these again. This is needed for the new binary repository: the initial build is done without existing APKINDEX files, so we must not fail in that case.
This commit is contained in:
parent
fa7860c8f6
commit
5102d48064
3 changed files with 28 additions and 8 deletions
|
@ -130,7 +130,7 @@ def add_shortcuts(args):
|
|||
def add_cache(args):
|
||||
""" Add a caching dict (caches parsing of files etc. for the current
|
||||
session) """
|
||||
repo_update = {"offline_msg_shown": False}
|
||||
repo_update = {"404": [], "offline_msg_shown": False}
|
||||
setattr(args, "cache", {"apkindex": {},
|
||||
"apkbuild": {},
|
||||
"apk_min_version_checked": [],
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue