mirror of
https://github.com/Abdess/retroarch_system.git
synced 2026-12-03 06:48:52 -06:00
fix: read file addresses in an offline run
This commit is contained in:
1 parent
0d0b6c54b7
commit
f161b0aefa
2 files changed
+11
-2
No files matched your search
@@ -385,10 +385,11 @@ def open_retrying(
|
||||
again in this process. What ends the attempts is raised as urllib gave
|
||||
it, except a host that does not resolve (GoneError) and a host muted
|
||||
earlier (RateLimitError). A run that fetches nothing (run_is_offline)
|
||||
raises OfflineError before anything goes out.
|
||||
raises OfflineError before anything goes out. A file: address is read
|
||||
from this machine and is never refused.
|
||||
"""
|
||||
url = request.full_url
|
||||
if run_is_offline():
|
||||
if run_is_offline() and request.type != "file":
|
||||
raise OfflineError(f"{url}: {OFFLINE_ENV} is set, nothing is fetched")
|
||||
host = urllib.parse.urlsplit(url).hostname or ""
|
||||
if host in _exhausted_hosts:
|
||||
|
||||
Reference in new issue
Block a user