Safe Haskell | Safe-Inferred |
---|---|
Language | Haskell2010 |
Synopsis
- data PlutusDebugOverrides = PlutusDebugOverrides {
- pdoScript ∷ !(Maybe ByteString)
- pdoProtocolVersion ∷ !(Maybe Version)
- pdoLanguage ∷ !(Maybe Language)
- pdoCostModelValues ∷ !(Maybe [Int64])
- pdoExUnitsMem ∷ !(Maybe Natural)
- pdoExUnitsSteps ∷ !(Maybe Natural)
- data PlutusWithContext where
- PlutusWithContext ∷ PlutusLanguage l ⇒ {..} → PlutusWithContext
- data ScriptFailure = ScriptFailure {}
- data ScriptResult
- scriptPass ∷ PlutusWithContext → ScriptResult
- scriptFail ∷ ScriptFailure → ScriptResult
- data PlutusDebugInfo
- debugPlutus ∷ String → PlutusDebugOverrides → IO PlutusDebugInfo
- runPlutusScript ∷ PlutusWithContext → ScriptResult
- runPlutusScriptWithLogs ∷ PlutusWithContext → ([Text], ScriptResult)
- evaluatePlutusWithContext ∷ VerboseMode → PlutusWithContext → ([Text], Either EvaluationError ExBudget)
- explainPlutusEvaluationError ∷ PlutusWithContext → EvaluationError → ScriptResult
Documentation
data PlutusDebugOverrides Source #
PlutusDebugOverrides | |
|
Instances
data PlutusWithContext where Source #
This type contains all that is necessary from Ledger to evaluate a plutus script.
PlutusWithContext | |
|
Instances
Show PlutusWithContext Source # | |
Defined in Cardano.Ledger.Plutus.Evaluate | |
FromCBOR PlutusWithContext Source # | |
Defined in Cardano.Ledger.Plutus.Evaluate | |
ToCBOR PlutusWithContext Source # | |
Defined in Cardano.Ledger.Plutus.Evaluate toCBOR ∷ PlutusWithContext → Encoding Source # encodedSizeExpr ∷ (∀ t. ToCBOR t ⇒ Proxy t → Size) → Proxy PlutusWithContext → Size Source # encodedListSizeExpr ∷ (∀ t. ToCBOR t ⇒ Proxy t → Size) → Proxy [PlutusWithContext] → Size Source # | |
NFData PlutusWithContext Source # | |
Defined in Cardano.Ledger.Plutus.Evaluate rnf ∷ PlutusWithContext → () Source # | |
Eq PlutusWithContext Source # | |
Defined in Cardano.Ledger.Plutus.Evaluate |
data ScriptFailure Source #
Instances
Generic ScriptFailure Source # | |
Defined in Cardano.Ledger.Plutus.Evaluate from ∷ ScriptFailure → Rep ScriptFailure x Source # to ∷ Rep ScriptFailure x → ScriptFailure Source # | |
Show ScriptFailure Source # | |
Defined in Cardano.Ledger.Plutus.Evaluate | |
type Rep ScriptFailure Source # | |
Defined in Cardano.Ledger.Plutus.Evaluate type Rep ScriptFailure = D1 ('MetaData "ScriptFailure" "Cardano.Ledger.Plutus.Evaluate" "cardano-ledger-core-1.17.0.0-inplace" 'False) (C1 ('MetaCons "ScriptFailure" 'PrefixI 'True) (S1 ('MetaSel ('Just "scriptFailureMessage") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Text) :*: S1 ('MetaSel ('Just "scriptFailurePlutus") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 PlutusWithContext))) |
data ScriptResult Source #
Instances
data PlutusDebugInfo Source #
DebugBadHex String | |
DebugCannotDecode String | |
DebugSuccess | |
DebugFailure | |
|
Instances
Show PlutusDebugInfo Source # | |
Defined in Cardano.Ledger.Plutus.Evaluate |
evaluatePlutusWithContext ∷ VerboseMode → PlutusWithContext → ([Text], Either EvaluationError ExBudget) Source #
explainPlutusEvaluationError ∷ PlutusWithContext → EvaluationError → ScriptResult Source #
Explain why a script might fail. Scripts come in three flavors:
- with 3 arguments
[data,redeemer,context]
forPlutusV1
andPlustuV2
- with 2 arguments
[redeemer,context]
forPlutusV1
andPlustuV2
- with 1 argument
context
forPlutusV3
onwards