mirror of
https://github.com/gradio-app/gradio.git
synced 2025-03-07 11:46:51 +08:00
fixed requests connection
This commit is contained in:
parent
0c0c8109a6
commit
db9c6bc603
@ -311,5 +311,5 @@ def url_ok(url):
|
||||
try:
|
||||
r = requests.head(url)
|
||||
return r.status_code == 200 or r.status_code == 401
|
||||
except ConnectionError:
|
||||
except (ConnectionError, requests.exceptions.ConnectionError):
|
||||
return False
|
||||
|
Loading…
Reference in New Issue
Block a user