Update bettercap.py

This commit is contained in:
Jeroen Oudshoorn
2024-01-05 22:04:31 +01:00
parent 88668fb4f8
commit 40aadc93cc

View File

@ -100,8 +100,11 @@ class Client(object):
await asyncio.sleep(sleep_time)
continue
except OSError:
logging.warning('[bettercap] connection to the bettercap endpoint failed...')
pwnagotchi.reboot()
sleep_time = min_sleep + max_sleep * random.random()
logging.warning('connection to the bettercap endpoint failed...')
logging.warning('retrying connection in {} sec'.format(sleep_time))
await asyncio.sleep(sleep_time)
continue
def run(self, command, verbose_errors=True):
while True: