mirror of
https://github.com/LBRYFoundation/LBRY-Vault.git
synced 2025-08-31 17:31:36 +00:00
network: fix proxy case
follow-up "healty spread of servers" d8f3ab0917
This commit is contained in:
parent
2dca91d048
commit
c49d5f672c
2 changed files with 6 additions and 1 deletions
|
@ -628,7 +628,10 @@ class Interface(PrintError):
|
|||
def do_bucket():
|
||||
if self.is_tor():
|
||||
return BUCKET_NAME_OF_ONION_SERVERS
|
||||
ip_addr = ip_address(self.ip_addr())
|
||||
try:
|
||||
ip_addr = ip_address(self.ip_addr())
|
||||
except ValueError:
|
||||
return ''
|
||||
if not ip_addr:
|
||||
return ''
|
||||
if ip_addr.version == 4:
|
||||
|
|
|
@ -760,6 +760,8 @@ class Network(PrintError):
|
|||
# main interface is exempt. this makes switching servers easier
|
||||
if iface_to_check.is_main_server():
|
||||
return True
|
||||
if not iface_to_check.bucket_based_on_ipaddress():
|
||||
return True
|
||||
# bucket connected interfaces
|
||||
with self.interfaces_lock:
|
||||
interfaces = list(self.interfaces.values())
|
||||
|
|
Loading…
Add table
Reference in a new issue