fix: remove check_interval restriction for non-pro plans
Simulation is paper trade only, so no need to restrict check_interval. Allow 10 second intervals for all users.
This commit is contained in:
@@ -141,15 +141,11 @@ async def start_simulation(
|
|||||||
settings = get_settings()
|
settings = get_settings()
|
||||||
simulation_id = str(uuid.uuid4())
|
simulation_id = str(uuid.uuid4())
|
||||||
|
|
||||||
check_interval = config.check_interval
|
|
||||||
if settings.AVE_API_PLAN != "pro" and check_interval < 60:
|
|
||||||
check_interval = 60
|
|
||||||
|
|
||||||
simulation_config = {
|
simulation_config = {
|
||||||
"bot_id": bot_id,
|
"bot_id": bot_id,
|
||||||
"token": config.token,
|
"token": config.token,
|
||||||
"chain": config.chain,
|
"chain": config.chain,
|
||||||
"check_interval": check_interval,
|
"check_interval": config.check_interval,
|
||||||
"auto_execute": False, # Always paper trade
|
"auto_execute": False, # Always paper trade
|
||||||
"strategy_config": bot.strategy_config,
|
"strategy_config": bot.strategy_config,
|
||||||
"ave_api_key": settings.AVE_API_KEY,
|
"ave_api_key": settings.AVE_API_KEY,
|
||||||
@@ -164,7 +160,7 @@ async def start_simulation(
|
|||||||
config={
|
config={
|
||||||
"token": config.token,
|
"token": config.token,
|
||||||
"chain": config.chain,
|
"chain": config.chain,
|
||||||
"check_interval": check_interval,
|
"check_interval": config.check_interval,
|
||||||
},
|
},
|
||||||
signals=[],
|
signals=[],
|
||||||
)
|
)
|
||||||
|
|||||||
Reference in New Issue
Block a user