atlas-cardano-0.5.0: Application backend for Plutus smart contracts on Cardano
Copyright(c) 2023 GYELD GMBH
LicenseApache 2.0
Maintainer[email protected]
Stabilitydevelop
Safe HaskellSafe-Inferred
LanguageGHC2021

GeniusYield.TxBuilder.Errors

Description

 
Synopsis

Documentation

data PlutusToCardanoError #

PlutusToCardanoError is raised when using Plutus to Cardano API type conversion functions from plutus-ledger. It is a focused version of Ledger.Tx.CardanoAPI.ToCardanoError.

Constructors

DeserialiseRawBytesError

Deserialization failed; tag indicates the type being deserialized.

Fields

StakePtrAddressUnsupported Address

Raised when trying to convert a stake ptr plutus address.

UnknownPlutusToCardanoError

Wildcard unhandled constructors; shouldn't happen usually.

Fields

data GYConversionError #

GYConversionErrors may be raised during type conversions.

Constructors

GYNotPubKeyAddress !GYAddress

An address was expected to contain a pub key hash, but it did not.

GYNotScriptAddress !GYAddress

An address was expected to contain a script hash, but it did not.

GYInvalidPlutusValue !GYFromPlutusValueError !Value

Raised during Plutus Value to GYValue conversion.

GYInvalidPlutusAsset !GYFromPlutusValueError

Raised during Plutus asset to GY asset conversion.

GYInvalidAddressText !Text

Raised when trying to parse Text into GYAddress.

GYEraSummariesToSlotConfigError !Text

Raised when trying to convert EraHistory to GYSlotConfig.

GYLedgerToCardanoError !PlutusToCardanoError

Errors raised during plutus-ledger -> cardano api type conversion.

GYInvalidAssetClass !Text

Errors raised by "GeniusYield.Types.Value.parseAssetClassCore" and similar.

GYInvalidSlot !Integer

Errors caused by "GeniusYield.Types.Slot.slotFromInteger" resulting in Nothing.

Instances

Instances details
Show GYConversionError # 
Instance details

Defined in GeniusYield.TxBuilder.Errors

data GYQueryUTxOError #

GYQueryUTxOErrors may be raised during utxo related queries.

Constructors

GYNoUtxosAtAddress ![GYAddress]

An address was queried for one or more UTxOs but none were found.

GYNoUtxoAtRef !GYTxOutRef

No UTxO exists at given ref.

Instances

Instances details
Show GYQueryUTxOError # 
Instance details

Defined in GeniusYield.TxBuilder.Errors

data GYQueryDatumError #

GYQueryDatumError may be raised during fetching and parsing datums.

Constructors

GYNoDatumForHash !GYDatumHash

No datum found for given hash.

GYInvalidDatum !GYDatum

Datum parsing failed.

GYNoDatumHash !GYUTxO

No datum hash at utxo.

Instances

Instances details
Show GYQueryDatumError # 
Instance details

Defined in GeniusYield.TxBuilder.Errors

data GYTxMonadExceptionType where #

Exceptions raised within the GYTxMonad computation.

This includes exceptions raised within the contract itself. It does not include:

  • Exceptions that may be raised by the provider.
  • Exceptions raised during transaction building/balancing.
  • Other wildcard exceptions raised within IO.

Constructors

GYConversionExceptionGYConversionErrorGYTxMonadException

Errors encountered during type conversions.

GYQueryUTxOExceptionGYQueryUTxOErrorGYTxMonadException

Errors encountered during utxo related queries.

GYNoSuitableCollateralException

Raised when no suitable collateral of at least tmeMinLovelace amount is found at tmeAddress.

Fields

GYSlotOverflowException

Raised if tmeSlot value overflows when advancing it by tmeAdvanceAmount.

Fields

GYTimeUnderflowExceptionSystemStartGYTimeGYTxMonadException

Raised during time -> slot conversion, if given timestamp is before known system start.

GYQueryDatumExceptionGYQueryDatumErrorGYTxMonadException

Raised during fetching/parsing datums.

GYDatumMismatchGYOutDatumGYTxIn v → GYTxMonadException

When actual datum in the UTxO is different than what is mentioned for in witness.

GYApplicationException ∷ (Exception e, IsGYApiError e) ⇒ e → GYTxMonadException

Wildcard user application specific errors. This is the "plug-in" point where an application using the GY framework, can raise its own protocol specific errors within GYTxMonad.

Instances

Instances details
Exception GYTxMonadException # 
Instance details

Defined in GeniusYield.TxBuilder.Errors

Show GYTxMonadException # 
Instance details

Defined in GeniusYield.TxBuilder.Errors

MonadError GYTxMonadException GYTxMonadNode # 
Instance details

Defined in GeniusYield.TxBuilder.Node

MonadError GYTxMonadException GYTxQueryMonadNode # 
Instance details

Defined in GeniusYield.TxBuilder.NodeQuery

MonadError GYTxMonadException GYTxMonadRun # 
Instance details

Defined in GeniusYield.TxBuilder.Run

GYTxMonad m ⇒ GYTxMonad (ExceptT GYTxMonadException m) # 
Instance details

Defined in GeniusYield.TxBuilder.Class

GYTxQueryMonad m ⇒ GYTxQueryMonad (ExceptT GYTxMonadException m) # 
Instance details

Defined in GeniusYield.TxBuilder.Class

Methods

networkIdExceptT GYTxMonadException m GYNetworkId #

lookupDatumGYDatumHashExceptT GYTxMonadException m (Maybe GYDatum) #

utxoAtTxOutRefGYTxOutRefExceptT GYTxMonadException m (Maybe GYUTxO) #

utxoAtTxOutRefWithDatumGYTxOutRefExceptT GYTxMonadException m (Maybe (GYUTxO, Maybe GYDatum)) #

utxosAtTxOutRefs ∷ [GYTxOutRef] → ExceptT GYTxMonadException m GYUTxOs #

utxosAtTxOutRefsWithDatums ∷ [GYTxOutRef] → ExceptT GYTxMonadException m [(GYUTxO, Maybe GYDatum)] #

utxosAtAddressGYAddressMaybe GYAssetClassExceptT GYTxMonadException m GYUTxOs #

utxosAtAddressWithDatumsGYAddressMaybe GYAssetClassExceptT GYTxMonadException m [(GYUTxO, Maybe GYDatum)] #

utxosAtAddresses ∷ [GYAddress] → ExceptT GYTxMonadException m GYUTxOs #

utxosAtAddressesWithDatums ∷ [GYAddress] → ExceptT GYTxMonadException m [(GYUTxO, Maybe GYDatum)] #

utxoRefsAtAddressGYAddressExceptT GYTxMonadException m [GYTxOutRef] #

utxosAtPaymentCredentialGYPaymentCredentialMaybe GYAssetClassExceptT GYTxMonadException m GYUTxOs #

utxosAtPaymentCredentialWithDatumsGYPaymentCredentialMaybe GYAssetClassExceptT GYTxMonadException m [(GYUTxO, Maybe GYDatum)] #

utxosAtPaymentCredentials ∷ [GYPaymentCredential] → ExceptT GYTxMonadException m GYUTxOs #

utxosAtPaymentCredentialsWithDatums ∷ [GYPaymentCredential] → ExceptT GYTxMonadException m [(GYUTxO, Maybe GYDatum)] #

stakeAddressInfoGYStakeAddressExceptT GYTxMonadException m (Maybe GYStakeAddressInfo) #

slotConfigExceptT GYTxMonadException m GYSlotConfig #

slotOfCurrentBlockExceptT GYTxMonadException m GYSlot #

logMsgGYLogNamespaceGYLogSeverityStringExceptT GYTxMonadException m () #

throwAppError ∷ (IsGYApiError e, Exception e, MonadError GYTxMonadException m) ⇒ e → m a #

Throw an application specific exception (GYApplicationException) within GYTxMonad.