fix display log with actual seconds bioeb, and reduce time
This commit is contained in:
parent
6cfb846e81
commit
0fa03940a0
1 changed files with 3 additions and 2 deletions
5
ubot.py
5
ubot.py
|
@ -423,9 +423,10 @@ async def main():
|
||||||
logger.debug(
|
logger.debug(
|
||||||
f'latency avocado reply: {delta_avocado} secs')
|
f'latency avocado reply: {delta_avocado} secs')
|
||||||
if delta_avocado > states.avocado_reply_timeout:
|
if delta_avocado > states.avocado_reply_timeout:
|
||||||
|
interval_with_lag = rs + random.uniform(9.18299148, 40.9201412499)
|
||||||
logger.debug(
|
logger.debug(
|
||||||
f'bioeb sleep [increased, because avocado have lag]: {rs}s')
|
f'bioeb sleep [increased, because avocado have lag]: {interval_with_lag}s')
|
||||||
await asyncio.sleep(rs + random.uniform(34, 69))
|
await asyncio.sleep(interval_with_lag)
|
||||||
else:
|
else:
|
||||||
logger.debug(f'bioeb sleep: {rs}s')
|
logger.debug(f'bioeb sleep: {rs}s')
|
||||||
await asyncio.sleep(rs)
|
await asyncio.sleep(rs)
|
||||||
|
|
Loading…
Reference in a new issue