Skip to content

fix(wallets): trezorCoin returns Connect shortcuts - #530

Merged
jpcummins merged 1 commit into
caravan-bitcoin:mainfrom
Rob-Ferguson:fix/trezor-connect-coin-shortcuts
Aug 22, 2026
Merged

fix(wallets): trezorCoin returns Connect shortcuts#530
jpcummins merged 1 commit into
caravan-bitcoin:mainfrom
Rob-Ferguson:fix/trezor-connect-coin-shortcuts

Conversation

@Rob-Ferguson

@Rob-Ferguson Rob-Ferguson commented Aug 21, 2026

Copy link
Copy Markdown
Contributor

Fixes #529

Suite 26.8+ looks up Connect coin by shortcut only. Bitcoin / Testnet / Regtest throw Method_UnknownCoin.

trezorCoin() now returns btc / test / regtest. Shortcuts still work on 26.7.4. blockchainSetCustomBackend coin is regtest.

Address-confirm copy still says Bitcoin / Testnet / Regtest.

Tests assert "btc" and "test". No "regtest" assertion because TREZOR_DEV is captured at import.

@caravan/wallets minor: exported trezorCoin return values changed. Callers comparing to "Bitcoin" / "Testnet" / "Regtest" need to update.

Suite 26.8+ rejects coin names. Return btc/test/regtest so signing works
on both current and older Suite.
@changeset-bot

changeset-bot Bot commented Aug 21, 2026

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: d3ca0b1

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@caravan/wallets Minor

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@vercel

vercel Bot commented Aug 21, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
caravan-coordinator Ready Ready Preview Aug 21, 2026 11:12pm

Request Review

@Rob-Ferguson
Rob-Ferguson marked this pull request as ready for review August 21, 2026 23:13

@jpcummins jpcummins left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I ran through the manual Trezor test suite in the following scenarios:

Trezor Suite 26.7.4 without fix to establish baseline compatibility - 6 errors:

  1. sign testnet transaction w/ 2 outputs and 3 inputs (P2SH)
  2. sign testnet transaction w/ 2 outputs and 3 inputs (P2SH-P2WSH)
  3. sign testnet transaction w/ 2 outputs and 3 inputs (P2WSH)
  4. sign mainnet transaction w/ 2 outputs and 3 inputs (P2SH)
  5. Confirm testnet P2SH multisig address
  6. Confirm mainnet P2SH multisig address

Trezor Suite 26.7.4 with fix to test backwards compatibility - 6 errors. No new errors introduced:

  1. sign testnet transaction w/ 2 outputs and 3 inputs (P2SH)
  2. sign testnet transaction w/ 2 outputs and 3 inputs (P2SH-P2WSH)
  3. sign testnet transaction w/ 2 outputs and 3 inputs (P2WSH)
  4. sign mainnet transaction w/ 2 outputs and 3 inputs (P2SH)
  5. Confirm testnet P2SH multisig address
  6. Confirm mainnet P2SH multisig address

Trezor Suite 26.8.2 without fix to confirm additional errors - 1 failure, 8 errors

  1. sign testnet transaction w/ 2 outputs and 3 inputs (P2SH)
  2. sign testnet transaction w/ 2 outputs and 3 inputs (P2SH-P2WSH)
  3. sign testnet transaction w/ 2 outputs and 3 inputs (P2WSH)
  4. sign mainnet transaction w/ 2 outputs and 3 inputs (P2SH)
  5. sign mainnet transaction w/ 2 outputs and 3 inputs (P2SH-P2WSH)
  6. sign mainnet transaction w/ 2 outputs and 3 inputs (P2WSH)
  7. Confirm testnet P2SH multisig address
  8. [failure] Confirm testnet P2WSH multisig address
  9. Confirm mainnet P2SH multisig address

Trezor Suite 26.8.2 with fix to confirm additional errors - 6 errors:

  1. sign testnet transaction w/ 2 outputs and 3 inputs (P2SH)
  2. sign testnet transaction w/ 2 outputs and 3 inputs (P2SH-P2WSH)
  3. sign testnet transaction w/ 2 outputs and 3 inputs (P2WSH)
  4. sign mainnet transaction w/ 2 outputs and 3 inputs (P2SH)
  5. Confirm testnet P2SH multisig address
  6. Confirm mainnet P2SH multisig address

I've confirmed this patch fixes the issue and doesn't introduce any backward incompatibility or other new errors.

@jpcummins
jpcummins merged commit 9a69e9c into caravan-bitcoin:main Aug 22, 2026
9 checks passed
@github-actions github-actions Bot mentioned this pull request Aug 22, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

trezorCoin() still sends Connect coin names (Bitcoin / Testnet / Regtest); Suite 26.8+ requires shortcuts (btc / test / regtest)

3 participants