From ae5b70ea2acf0a02129681db148d301a7d5a43ee Mon Sep 17 00:00:00 2001 From: Eric Swanson <64809312+ericswanson-dfinity@users.noreply.github.com> Date: Tue, 19 Sep 2023 08:37:56 -0700 Subject: [PATCH] fix: remove duplicate builder.with_arg in wallet call (#3372) When making a call with the wallet, we had two calls to `builder.with_arg()`. With the current agent this (probably) just adds a parameter that will be ignored, but with the 0.27.0 rust agent this causes a `argument is being set more than once` panic. This will fix the e2e failures on https://github.com/dfinity/sdk/pull/3370 --- CHANGELOG.md | 4 ++++ src/dfx/src/commands/canister/call.rs | 1 - 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 27ee506d80..74cea9f8d6 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -57,6 +57,10 @@ Background: In order to determine whether to start a project-specific network or If `dfx start` is starting the shared network from within a dfx project, and that dfx.json contains settings in the `defaults` key for `bitcoin`, `replica`, or `canister_http`, then `dfx start` will warn that it is ignoring those settings. It will also describe how to define equivalent settings in networks.json. +### fix: dfx canister call --wallet no longer passes the parameter twice + +The parameter was erroneously passed twice. Now it is passed only once. + ## Dependencies ### Frontend canister diff --git a/src/dfx/src/commands/canister/call.rs b/src/dfx/src/commands/canister/call.rs index c8bfc11fbe..9f8eb53418 100644 --- a/src/dfx/src/commands/canister/call.rs +++ b/src/dfx/src/commands/canister/call.rs @@ -111,7 +111,6 @@ async fn do_wallet_call(wallet: &WalletCanister<'_>, args: &CallIn) -> DfxResult wallet.update_("wallet_call").with_arg(args64) }; let (result,): (Result,) = builder - .with_arg(args) .build() .call_and_wait() .await