Skip to content

Conversation

@OttoAllmendinger
Copy link
Contributor

@OttoAllmendinger OttoAllmendinger commented Oct 20, 2025

This merges the full history of https://github.com/BitGo/wasm-miniscript (beta branch) as the baseline.

Further PRs will rename the directories and packages to wasm-utxo and extend the functionality to BitGo fixed-script wallets.

bitgobot and others added 30 commits July 11, 2024 15:38
Add initial version of wasm-miniscript package
refactor: move build output to dist/ directory
feat: add typescript as a dependency
So that Mac M1 users can run wasm-pack successfully, otherwise it throws
error.

BTC-1317
BTC-1333: Build wasm files for Mac M1 using Docker and Makefile
feat: add `all` target and some clean up commands
* add to `type Descriptor`:
  - `hasWildcard` method
  - `atDerivationIndex` method
  - `toAsmString` method
* add to `type Miniscript`:
  - `toAsmString` method
* add parameter `pkType` to `descriptorFromString` function

Issue: BTC-1317
feat: add a `publish.yml` for publishing packages to npmjs
ci: switch to dtolnay/rust-toolchain
ci: fix publish workflow trigger
chore: add necessary publish configuration
feat: add formatNode utility for descriptor and miniscript ASTs
Upstream changes
Adds missing Drop node mapping to AST parser. Includes new test fixture.

Issue: BTC-1826
Add AST support for taproot trees in descriptors, including type definitions
and formatNode handling. Add fixtures for tree-based descriptors.

Issue: BTC-1829
Run wasm-opt separately after build to enable bulk memory.

This fixes compilation problems with rust nightly.

Issue: BTC-0
Add PSBT signing functionality using private extended keys (xprv).
Supports individual key signing and returns a map of signed pubkeys.

Issue: BTC-1845
Rewrite descriptor template strings as AST nodes for better reliability.
Replace string templates with explicit AST node construction.

Issue: BTC-1845
Files renamed to better indicate their purpose for fixed script compatibility.

Issue: BTC-1845
Adds utils to create and test PSBTs from descriptors with mock inputs and
outputs.

Issue: BTC-1845
Implement PSBT signing with raw private keys alongside xprv-based signing. Add
tests to verify both signing methods.

Issue: BTC-1845
Standardize wasm tools installation across CI and publish workflows.
Add version output for better debugging.

Issue: BTC-1845
It is only a dev dependency but whatever

Issue: beta
Handle descriptors without wildcards in psbt mock utilities

Issue: beta
Adds SingleKeySigner implementation to sign with plain EC keys for taproot
descriptors.

Issue: beta
Reduce distance between both branches

Issue: BTC-1829
Replaces JsError with WasmMiniscriptError.

This allows writing tests for funcs that return
`Result<_, WasmMiniscriptError>`. Previously it was a pain because
`JsError` did not implement Debug.

Issue: BTC-1826
Add fromStringDetectType() that auto-detects whether a descriptor contains
wildcards. If it does, returns a derivable descriptor, otherwise a definite
one.

Issue: BTC-1826
Merging beta instead of master because that is the de-facto branch that is used
for the wasm-miniscript package.
Rearrange imports and improve code formatting to follow project style.
Remove unnecessary trailing commas and clean up whitespace in tests.

Issue: BTC-2650

Co-authored-by: llm-git <llm-git@ttll.de>
@OttoAllmendinger OttoAllmendinger requested review from ppongbitgo and removed request for ppongbitgo October 20, 2025 11:23
@OttoAllmendinger OttoAllmendinger merged commit 02f4afd into master Oct 20, 2025
2 checks passed
@OttoAllmendinger OttoAllmendinger deleted the BTC-2650.add-wasm-utxo branch October 20, 2025 13:12
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.

10 participants