feat(manager): implement dynamic scan interval (37s when idle, 666s when active)

This commit is contained in:
2025-12-21 16:32:54 +01:00
parent ee457d0a51
commit 85e4e6508d

View File

@ -810,7 +810,7 @@ def main():
pass pass
elif OPEN_POSITION_ENABLED: elif OPEN_POSITION_ENABLED:
logger.info("🔍 No active position. Analyzing market...") logger.info("🔍 No active position. Analyzing market (Fast scan: 37s)...")
# Setup logic for new position # Setup logic for new position
token0 = clean_address(WETH_ADDRESS) token0 = clean_address(WETH_ADDRESS)
@ -879,7 +879,9 @@ def main():
update_position_status(minted['token_id'], "OPEN", new_position_data) update_position_status(minted['token_id'], "OPEN", new_position_data)
time.sleep(MONITOR_INTERVAL_SECONDS) # Dynamic Sleep: 37s if no position, else configured interval
sleep_time = MONITOR_INTERVAL_SECONDS if active_auto_pos else 37
time.sleep(sleep_time)
except KeyboardInterrupt: except KeyboardInterrupt:
logger.info("👋 Exiting...") logger.info("👋 Exiting...")