We provide helpers and better high-level abstractions for spending taproot outputs via either the key path or script path. This ensures that callers can't mess up which SigVersion they use, or forget to include the script leaf hash or merkle root depending on what they are spending.
The caller only needs to remember:
the internal public key
the script tree
if they're using the script path, the ID of the script leaf they're using
That is information that they should always be able to keep around or recompute, and seems to be minimal.
NB: the two commits are somewhat independent and should be reviewed separately.
We provide helpers and better high-level abstractions for spending taproot outputs via either the key path or script path. This ensures that callers can't mess up which
SigVersion
they use, or forget to include the script leaf hash or merkle root depending on what they are spending.The caller only needs to remember:
That is information that they should always be able to keep around or recompute, and seems to be minimal.
NB: the two commits are somewhat independent and should be reviewed separately.