Skip to content

Add BCH and EVM to Bridgeless plugin#450

Open
peachbits wants to merge 4 commits intomasterfrom
matthew/bridgeless-bch
Open

Add BCH and EVM to Bridgeless plugin#450
peachbits wants to merge 4 commits intomasterfrom
matthew/bridgeless-bch

Conversation

@peachbits
Copy link
Copy Markdown
Contributor

@peachbits peachbits commented Mar 27, 2026

CHANGELOG

Does this branch warrant an entry to the CHANGELOG?

  • Yes
  • No

Dependencies

none

Description

none

Note

Medium Risk
Adds new chain support and new EVM transaction/approval flows in bridgeless, which could affect swap amounts, memos, and order tracking if encoding or decimal-scaling is incorrect.

Overview
Expands the bridgeless swap plugin to support additional source chains (Bitcoin Cash, Ethereum, BNB Chain) for swaps that involve Zano, including new chain-id mappings and routing.

Adds EVM deposit support by encoding depositNative/depositERC20 call data via ethers, generating ERC20 approval preTxs when needed, and adjusting orderId output-index handling for token deposits.

Updates quote amount math to account for differing token decimals across chains via new scaleNativeAmount (with tests), and generalizes receiver address formatting (Zano address hex-encoding vs passthrough for others).

Written by Cursor Bugbot for commit fc0bb79. This will update automatically on new commits. Configure here.


Add bitcoin cash chain id
Add zero address constant
Use correct fetch
Reaplce switch/case with if for Zano special case
The plugin isn't handling tokenId or decimals correctly. It just kind of worked for bitcoin because the number of decimals matched on both sides of the swap. For tokenId, only the fromWallet was used so the plugin is broken if the swap goes from token->token.
This is an arbitrary limitation. Other swaps should work (ie. bitcoin to ethereum btcx token) but they are untested.
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.

1 participant