-
Notifications
You must be signed in to change notification settings - Fork 158
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
redeemers check mistake #2393
redeemers check mistake #2393
Conversation
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.
good catch!
The unit test for "missing 2-phase script witness" is now also returning an addition predicate failure, namely:
Something seems wrong... |
those were redeemers for phase-1 scripts, there is only 1 phase-2 script (used for 1 purpose, so needs 1 redeemer, and the transaction has a total of 4) |
The example failure is fixed.. but now I do not understand why this is happening.. is it something to do with recent changes?: @nc6 it looks like the same error as in the latest merged PR build? `[6 of 9] Compiling Test.Cardano.Ledger.Alonzo.Tools ( test/Test/Cardano/Ledger/Alonzo/Tools.hs, dist/build/cardano-ledger-alonzo-test/cardano-ledger-alonzo-test-tmp/Test/Cardano/Ledger/Alonzo/Tools.o, dist/build/cardano-ledger-alonzo-test/cardano-ledger-alonzo-test-tmp/Test/Cardano/Ledger/Alonzo/Tools.dyn_o ) test/Test/Cardano/Ledger/Alonzo/Tools.hs:22:1: error: |
Ah, maybe suggests an out-of-order merge issue. I'll fix separately. |
I think we can cut down on the complexity now, if we really don't want the size check. |
I made the changes to the formal spec we just discussed |
These changes also made it obvious that we've been checking that all the scripts are present twice, so I've removed that duplicate as well. UTXOW looks a lot simpler now :) |
Thank you!! |
0f1861b
to
ba20b8e
Compare
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.
LGTM!
ExtraRedeemers | ||
[ RdmrPtr Tag.Mint 1, | ||
RdmrPtr Tag.Cert 1, | ||
RdmrPtr Tag.Rewrd 0 |
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.
So this predicate failure is happening because the lack of script witness means that we do not know that the script hash is a plutus script, and hence these look superfluous?
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.
yes, there is no plutus/phase-2 script validating those three things
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 think what's in here is technically equivalent to what's in the spec but it's not obvious. If someone else agrees, we could merge it and fix it later (probably as part of our current ongoing audit)
542a922
to
8367aa4
Compare
8367aa4
to
06f2655
Compare
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.
LGTM
I think we can merge this now, I'd probably like Polina to have another look at this but we probably don't want to wait till she's back |
as @WhatisRT points out, the current check for extra redeemers allowed redeemers for non-native scripts : (
this fixes that