nautechsystems/nautilus_trader · critical

Signer address derived from ' ' does not match configured…

Error message

Signer address {} derived from '{}' does not match configured wallet address {}

What it means

During execution client initialization, the adapter loads the private key from the configured env var and derives its address. If the derived signer address differs from the configured wallet_address, the configuration is inconsistent (funds/orders would be tied to the wrong account), so init fails with both addresses and the env var name.

Solutions

  1. Set config.wallet_address to the address derived from the private key in signer_private_key_env
  2. Or set the env var to the private key matching the configured wallet address
  3. Verify with cast wallet address --private-key $KEY (foundry) which address the key produces
  4. Check that the intended env var is actually set and no stale/different key is loaded

Example fix

// before
wallet_address = "0xAAAA..."
SIGNER_PRIVATE_KEY=0x<key for 0xBBBB...>
// after
wallet_address = "0xBBBB..."  # address matching SIGNER_PRIVATE_KEY
SIGNER_PRIVATE_KEY=0x<key>
Defensive patterns

Strategy: validation

Validate before calling

let signer = PrivateKeySigner::from_slice(&key_bytes)?;
if signer.address() != expected_wallet_address {
    return Err(anyhow::anyhow!("key/env address {} != configured {}", signer.address(), expected_wallet_address));
}

Try / catch

match ExecutionClient::new(config) {
    Ok(c) => run(c),
    Err(e) if e.to_string().contains("does not match configured wallet") => {
        eprintln!("fix wallet_address or SIGNER_PRIVATE_KEY"); std::process::exit(1);
    }
    Err(e) => return Err(e),
}

Prevention

When it happens

Trigger: Starting the execution client where the private key in signer_private_key_env corresponds to a different EOA than config.wallet_address.

Common situations: Rotating keys (new key env var, stale wallet_address in config); copy-pasting a wallet address from a different account; multiple env vars set and the wrong one is read.

Understand the failure class

Background: Checksum mismatch errors: "checksum verification failed", "digest mismatch", "expected vs actual checksum" — what they mean and how to fix them — this error's family across 41 libraries.

Related errors


AI-assisted analysis of nautechsystems/nautilus_trader@18893faf8b (2026-09-08). Data as JSON: /api/errors/6619e12ea63345f3. Report an issue: GitHub.

Appendix: source

Thrown at crates/adapters/blockchain/src/execution/client.rs:6188

                    "Signer private key environment variable '{}' is not set",
                    self.config.signer_private_key_env
                )
            })?,
        );
        let encoded_key = private_key.trim();
        let encoded_key = encoded_key.strip_prefix("0x").unwrap_or(encoded_key);
        let key_bytes = Zeroizing::new(hex::decode_array::<32>(encoded_key).map_err(|_| {
            anyhow::anyhow!(
                "Signer private key in '{}' is not a valid hex private key",
                self.config.signer_private_key_env
            )
        })?);
        let signer = PrivateKeySigner::from_slice(&key_bytes[..]).map_err(|_| {
            anyhow::anyhow!(
                "Signer private key in '{}' is not a valid secp256k1 private key",
                self.config.signer_private_key_env
            )
        })?;

        if signer.address() != self.wallet_address {
            anyhow::bail!(
                "Signer address {} derived from '{}' does not match configured wallet address {}",
                signer.address(),
                self.config.signer_private_key_env,
                self.wallet_address
            );
        }

        self.signer = Some(Arc::new(signer));
        drop(payload_connect_lease);

        if self.cache.has_database()
            && let Err(e) = self.reconcile_unresolved_execution().await
        {
            self.signer = None;
            return Err(e);

View on GitHub (pinned to 18893faf8b)