-
Notifications
You must be signed in to change notification settings - Fork 155
Thresh bug with equal verify #236
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
Conversation
roundtrip( | ||
&ms_str!("tv:thresh(1,pk(02d7924d4f7d43ea965a465ae3095ff41131e5946f3c85f79e44adbcf8e27e080e))", ), | ||
"Script(OP_PUSHBYTES_33 02d7924d4f7d43ea965a465ae3095ff41131e5946f3c85f79e44adbcf8e27e080e OP_CHECKSIG OP_PUSHNUM_1 OP_EQUALVERIFY OP_PUSHNUM_1)", | ||
); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I seem to only be able to reproduce it with a single subpolicy, which is not a valid Miniscript (see #242 ). EDIT: not the case anymore.
Also, a broader Miniscript question: why isn't the Script here 1 <pk> CHECKSIG ADD 1 EQUALVERIFY 1
(as i would have expected of a thresh
wrapped in a v
, wrapped in a and_v(X, 1)
) ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry, I have been away for a while. Will catch up with all the miniscript stuff this week.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
and_or
is a ternary fragment(3 args) and this is binary fragment(2 args). Why should we have and_or
here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry, i meant and_v
. Editing now.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
And i think i answered the question myself, ADD
is only appended if k > 1
. Sorry for the noise :)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ack 865bf4b
Parsing an
EQUALVERIFY
ending thresh fragment failed roundtrip.