Safe-CLI Transactions Fail with Trezor Wallet

Open
#511 5 comments 2 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
35/100
Issue type
Bug
Clarity
Mostly clear
Activity status
Stale
Tech stack
python
Domain
blockchain, cli

Research direction

Start by reproducing the failure with load_trezor_cli_owners and tx-sign in tx-service mode, then try approve_hash in blockchain mode. Trace the Safe-CLI entry points for these commands and the Trezor interaction to identify why signing returns “Unexpected message” and why the account is not loaded. Done means both transaction signing and hash approval work with a Trezor wallet.

Written by the indexing model from the issue text.

Description

bug SEV-4

I am trying to send transactions using the Safe-CLI with a Trezor wallet. The Trezor address is successfully imported via load_trezor_cli_owners, but signing transactions fails with the following error

HwDevice exception: Unexpected message

This occurs when running tx-sign in tx-service mode.

Additionally, when switching to blockchain mode, I encounter another issue when attempting to approve a hash:

Account 0x is not loaded

Steps to reproduce the behavior:

  1. Load a Trezor wallet into Safe-CLI:
    safe-cli load_trezor_cli_owners
    
  2. Attempt to sign a transaction in tx-service mode:
    safe-cli tx-sign <transaction>
    
  3. Observe the error:
    HwDevice exception: Unexpected message
    
  4. Switch to blockchain mode and try approving a hash:
    safe-cli approve_hash <hash> <sender>
    
  5. Observe the error:
    Account 0x00..1 is not loaded
    

The Safe-CLI should properly interact with the Trezor wallet to sign transactions without unexpected hardware errors.

Dominant language
Python
Stars
280
Forks
110
Avg merge
1d 11h
Merged PRs (30d)
5

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from safe-global/safe-cli

All issues in safe-global/safe-cli

Similar issues

More Python issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.