Skip to content

Commit

Permalink
fix: staking condition
Browse files Browse the repository at this point in the history
  • Loading branch information
Divya-Solulab committed Nov 15, 2024
1 parent 87ab546 commit b55741b
Showing 1 changed file with 10 additions and 9 deletions.
19 changes: 10 additions & 9 deletions run_service.py
Original file line number Diff line number Diff line change
Expand Up @@ -368,16 +368,17 @@ def configure_local_config() -> OptimusConfig:
if optimus_config.use_staking is None:
optimus_config.use_staking = input("Do you want to stake your service? (y/n): ").lower() == 'y'

if optimus_config.use_staking and optimus_config.staking_chain is None:
print("Possible staking chains are Mode and Optimism, with Mode being the default setting.")
switch_staking = input("Do you want to switch such setting to Optimism (y/n)?: ").lower() == 'y'
if switch_staking:
optimus_config.staking_chain = "optimism"
print("The staking chain has changed to Optimism.")
if optimus_config.staking_chain is None:
if optimus_config.use_staking:
print("Possible staking chains are Mode and Optimism, with Mode being the default setting.")
switch_staking = input("Do you want to switch such setting to Optimism (y/n)?: ").lower() == 'y'
if switch_staking:
optimus_config.staking_chain = "optimism"
print("The staking chain has changed to Optimism.")
else:
optimus_config.staking_chain = "mode"
else:
optimus_config.staking_chain = "mode"
else:
optimus_config.staking_chain = ""
optimus_config.staking_chain = ""

if optimus_config.principal_chain is None:
optimus_config.principal_chain = optimus_config.staking_chain if optimus_config.staking_chain else DEFAULT_STAKING_CHAIN
Expand Down

0 comments on commit b55741b

Please sign in to comment.