2019-07-22 05:24:42 +00:00
|
|
|
import filepaths, time
|
2019-07-18 17:40:48 +00:00
|
|
|
|
|
|
|
files = [filepaths.tor_hs_address_file]
|
2019-07-20 06:02:30 +00:00
|
|
|
|
|
|
|
def get():
|
|
|
|
transports = []
|
2019-07-24 16:32:23 +00:00
|
|
|
for file in files:
|
|
|
|
try:
|
|
|
|
with open(file, 'r') as transport_file:
|
|
|
|
transports.append(transport_file.read().strip())
|
|
|
|
except FileNotFoundError:
|
|
|
|
pass
|
2019-07-22 05:24:42 +00:00
|
|
|
else:
|
2019-07-24 16:32:23 +00:00
|
|
|
break
|
|
|
|
else:
|
|
|
|
time.sleep(1)
|
2019-07-20 06:02:30 +00:00
|
|
|
return list(transports)
|