Skip to content

refactor(wasm-utxo): extract base classes for PSBT and transaction#243

Open
OttoAllmendinger wants to merge 1 commit intomasterfrom
BTC-2992.base-classes
Open

refactor(wasm-utxo): extract base classes for PSBT and transaction#243
OttoAllmendinger wants to merge 1 commit intomasterfrom
BTC-2992.base-classes

Conversation

@OttoAllmendinger
Copy link
Copy Markdown
Contributor

Introduce PsbtBase and TransactionBase to eliminate duplication
across Psbt/BitGoPsbt and Transaction/ZcashTransaction/
DashTransaction. Common methods (input/output counts, serialization,
KV access) are now implemented once in the base classes.

On the Rust side, add a WasmPsbtOps trait and macro to generate
consistent WASM bindings. Move remove_input/remove_output into
the PsbtAccess trait for uniformity.

Co-authored-by: llm-git llm-git@ttll.de

Introduce `PsbtBase` and `TransactionBase` to eliminate duplication
across `Psbt`/`BitGoPsbt` and `Transaction`/`ZcashTransaction`/
`DashTransaction`. Common methods (input/output counts, serialization,
KV access) are now implemented once in the base classes.

On the Rust side, add a `WasmPsbtOps` trait and macro to generate
consistent WASM bindings. Move `remove_input`/`remove_output` into
the `PsbtAccess` trait for uniformity.

Co-authored-by: llm-git <llm-git@ttll.de>
@OttoAllmendinger OttoAllmendinger marked this pull request as ready for review April 2, 2026 12:47
@OttoAllmendinger OttoAllmendinger requested a review from a team as a code owner April 2, 2026 12:47
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