Skip connectivity check on env variable

main
Mateus Melchiades 2 years ago
parent 97c0f794fc
commit 504600ad41

@ -16,6 +16,7 @@
from urllib.request import urlopen from urllib.request import urlopen
from urllib.error import URLError from urllib.error import URLError
import os
from gi.repository import Gtk, GLib, Adw from gi.repository import Gtk, GLib, Adw
@ -51,6 +52,9 @@ class VanillaDefaultConnCheck(Adw.Bin):
def __start_conn_check(self): def __start_conn_check(self):
def async_fn(): def async_fn():
if "VANILLA_SKIP_CONN_CHECK" in os.environ:
return True
try: try:
urlopen("http://google.com", timeout=1) urlopen("http://google.com", timeout=1)
return True return True

Loading…
Cancel
Save