From add6963073888ff91b7d7e6f7d0d8163142845c3 Mon Sep 17 00:00:00 2001 From: KahanMajmudar Date: Wed, 11 Dec 2024 07:18:57 +0000 Subject: [PATCH] allows for optional staking --- run_service.py | 2 +- utils.py | 5 +++++ 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/run_service.py b/run_service.py index 30b0a62..a10a850 100644 --- a/run_service.py +++ b/run_service.py @@ -103,7 +103,7 @@ def get_service_template(config: MechQuickstartConfig) -> ServiceTemplate: "nft": "bafybeifgj3kackzfoq4fxjiuousm6epgwx7jbc3n2gjwzjgvtbbz7fc3su", "cost_of_bond": COST_OF_BOND, "threshold": 1, - "use_staking": True, + "use_staking": config.use_staking, "fund_requirements": FundRequirementsTemplate( { "agent": AGENT_TOPUP, diff --git a/utils.py b/utils.py index ed4d2ba..02c4a62 100644 --- a/utils.py +++ b/utils.py @@ -320,6 +320,11 @@ def get_local_config() -> MechQuickstartConfig: mech_quickstart_config.gnosis_rpc = input( f"Please enter a {ChainType.from_id(mech_quickstart_config.home_chain_id).name} RPC URL: " ) + + if mech_quickstart_config.use_staking is None: + mech_quickstart_config.use_staking = input_with_default_value( + "Do you wish to use staking for your service? (True/False)" , False + ) if mech_quickstart_config.mech_hash is None: mech_hash = (