-
-
Notifications
You must be signed in to change notification settings - Fork 141
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
Register Stake requires redeemer for scripts on PlutusV3 #270
Comments
Hey @MicroProofs! Thanks for the hint, I was about to change the code, but then noticed I was able to submit a tx without redeemer, and uplc even fails with "redeemer points to an unsupported certificate type" if I use a redeemer for registerStake. Here the tx: https://preview.cardanoscan.io/transaction/a5debf5fa7491a950c7da0206601a7debe8405954e0f317bea1c448b58f949e3?tab=stakecertificates {
type: "PlutusV3",
script:
"586001010029800aba2aba1aab9eaab9dab9a4888896600264646644b30013370e900318031baa002899199119b8748028dd698058031bad30090013009300a00130073754005164014600c600e002600c004600c00260066ea801a29344d9590011",
} Am I missing something? Edit: |
Ahh that confused me I thought they changed the behavior in V3 but I guess not? |
Thanks for checking I saw it as an update I thought in the Cardano-ledger but maybe it was reverted? Edit: nvm I think I mistook it for the drep registration like you pointed out |
But also there is this comment -- For both of the functions |
|
Okay I see there are two new certificate types Seems like a transformation is necessary for V1V2 context, where you extract the credential and leave out the deposit transTxCertV1V2 ::
( ConwayEraTxCert era
, Inject (ConwayContextError era) (ContextError era)
) =>
TxCert era ->
Either (ContextError era) PV1.DCert
transTxCertV1V2 = \case
RegDepositTxCert stakeCred _deposit ->
Right $ PV1.DCertDelegRegKey (PV1.StakingHash (transCred stakeCred))
UnRegDepositTxCert stakeCred _refund ->
Right $ PV1.DCertDelegDeRegKey (PV1.StakingHash (transCred stakeCred))
txCert
| Just dCert <- Alonzo.transTxCertCommon txCert -> Right dCert
| otherwise -> Left $ inject $ CertificateNotSupported txCert |
No description provided.
The text was updated successfully, but these errors were encountered: