-
Notifications
You must be signed in to change notification settings - Fork 139
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
Better error messages on satisfiers #721
Comments
So, in general there is no single "reason" that satisfaction fails. You can imagine that instead of a Having said this, throughout the codebase we have dozens of somewhat-obscure reasons for failing satisfaction. In this case in A few observations:
|
I've been learning rust-miniscript, and when attempting to try out timelocks, I kept hitting a
CouldNotSatisfy
when finalizing my psbt. The reason turned out to be totally of my own doing - I had inadvertantly used aSequence::MAX
instead of aSequence::ZERO
when constructing my spend transaction. I had effectively disabled locktime usage, because I had done this:instead of this:
I was so preoccupied trying to figure out how signing worked, how to use the
plan
module etc that I didn't notice this.In order to figure out the problem, I ran my own local forks of
bdk_wallet
,rust-miniscript
, andbitcoin
crates, instrumenting them with printlns until I figure out what the (dumb, self-inflicted) problem was.It would be supersonic if satisfier errors gave a more specific reason for failure - I wonder if it would be possible for instance to turn
CouldNotSatisfy
into something likeCouldNotSatisfy("here is the reason")
? Or perhaps something more typed like (in the case I just dealt with)CouldNotSatisfy(LockTimeDisabled)
?The text was updated successfully, but these errors were encountered: