-
Notifications
You must be signed in to change notification settings - Fork 213
Fix missing datums for toCardanoTxBody #167
Fix missing datums for toCardanoTxBody #167
Conversation
Maybe the same thing should be applied to cardano-api, since the fix in the code that was copied from that repo, |
@anton-k The change has already been applied after we copied it! https://github.com/input-output-hk/cardano-node/blob/master/cardano-api/src/Cardano/Api/TxBody.hs#L2600 It looks like your |
Just datum -> pure $ C.TxOutDatum C.ScriptDataInAlonzoEra (toScriptData $ P.getDatum datum) | ||
Nothing -> toCardanoTxOutDatumHash datumHash | ||
|
||
toScriptData :: P.BuiltinData -> C.ScriptData |
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.
Isn't this the same as toCardanoScriptData
?
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.
Indeed, I've fixed that
We need nub in case if we have several inputs with the same script, otherwise witness is going to be duplicated. |
Thanks! |
@sjoerdvisscher Thanks for merging! |
@anton-k I agree, could you open an issue (or PR) against |
Fixes #139