Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for cold wallet #1497

Merged
merged 4 commits into from
Jan 25, 2024
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 2 additions & 3 deletions test/functional/wallet_decommission_request.py
Original file line number Diff line number Diff line change
Expand Up @@ -224,7 +224,7 @@ async def async_test(self):
node = self.nodes[0]
decommission_address = ""

async with WalletCliController(node, self.config, self.log, chain_config_args=["--chain-pos-netupgrades", "true"]) as wallet:
async with WalletCliController(node, self.config, self.log, chain_config_args=["--chain-pos-netupgrades", "true", "--cold-wallet"]) as wallet:
# new cold wallet
await wallet.create_wallet("cold_wallet")

Expand Down Expand Up @@ -299,10 +299,9 @@ async def async_test(self):

decommission_signed_tx = ""

async with WalletCliController(node, self.config, self.log, chain_config_args=["--chain-pos-netupgrades", "true"]) as wallet:
async with WalletCliController(node, self.config, self.log, chain_config_args=["--chain-pos-netupgrades", "true", "--cold-wallet"]) as wallet:
# open cold wallet
await wallet.open_wallet("cold_wallet")
assert_in("Success", await wallet.sync())

# sign decommission request
decommission_signed_tx_output = await wallet.sign_raw_transaction(decommission_req)
Expand Down
6 changes: 2 additions & 4 deletions wallet/wallet-cli-lib/src/cli_event_loop.rs
Original file line number Diff line number Diff line change
Expand Up @@ -37,14 +37,12 @@ pub async fn run(
chain_config: &Arc<ChainConfig>,
mut event_rx: mpsc::UnboundedReceiver<Event>,
in_top_x_mb: usize,
node_rpc_address: Option<String>,
node_credentials: RpcAuthData,
node_opts: Option<(Option<String>, RpcAuthData)>,
) -> Result<(), WalletCliError> {
let mut command_handler = CommandHandler::new(
ControllerConfig { in_top_x_mb },
chain_config.clone(),
node_rpc_address,
node_credentials,
node_opts,
)
.await?;

Expand Down
Loading
Loading