Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Inconsistent input size estimation from the planning module #701

Open
darosior opened this issue Jun 24, 2024 · 0 comments
Open

Inconsistent input size estimation from the planning module #701

darosior opened this issue Jun 24, 2024 · 0 comments

Comments

@darosior
Copy link
Contributor

plan() takes into account the leaf script + control block for Taproot but not the witness script for P2WSH. This results in getting the maximum witness size for the plan (witness_size()) sometimes taking into account the full satisfaction size (under Taproot) and sometimes not (under P2WSH), which is rather confusing.

As a hack we leveraged the explicit_script function to add the script size only under P2WSH since it returns None for Taproot: https://github.com/wizardsardine/liana/blob/bdc0b50ad9780ea29b77703c513a99fb5876fb21/src/descriptors/mod.rs#L261-L274

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

No branches or pull requests

1 participant