Skip to content

Commit

Permalink
chore: fix imports and comments
Browse files Browse the repository at this point in the history
  • Loading branch information
euonymos committed Dec 19, 2024
1 parent 7e5058f commit 8ce26d6
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 8 deletions.
9 changes: 4 additions & 5 deletions src/Cardano/CEM/OffChain.hs
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,6 @@ import Data.Map qualified as Map
import Data.Maybe (fromJust)
import Data.Singletons (sing)
import Data.Spine (HasSpine (..))
import Debug.Trace (traceShowId)
import Plutarch (Config (..), (#))
import Plutarch.Evaluate (evalTerm)
import Plutarch.Lift (pconstant, plift)
Expand Down Expand Up @@ -265,11 +264,11 @@ process (MkCEMAction params transition) ec = case ec of
-- -----------------------------------------------------------------------------

data TxResolutionError
= CEMScriptTxInResolutionError
| -- FIXME: record transition and action involved
= NoSignerError
| CEMScriptTxInResolutionError
| -- TODO: record transition and action involved
PerTransitionErrors [TransitionError]
| -- FIXME: this is weird
UnhandledSubmittingError TxSubmittingError
| UnhandledSubmittingError TxSubmittingError
deriving stock (Show)

resolveTx ::
Expand Down
6 changes: 3 additions & 3 deletions src/Cardano/CEM/Testing/StateMachine.hs
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ import Cardano.CEM.Monads (
)
import Cardano.CEM.Monads.CLB (ClbRunner, execOnIsolatedClb)
import Cardano.CEM.OffChain (
TxResolutionError (CEMScriptTxInResolutionError, UnhandledSubmittingError),
TxResolutionError (NoSignerError, UnhandledSubmittingError),
compileActionConstraints,
construct,
process,
Expand Down Expand Up @@ -396,9 +396,9 @@ instance
let
(cs, _) = applyMutation mutation cs'
mbSignerPKH = getMbMainSigner cs
-- \| FIXME: can we delegate handling Nothing case to process/construct?
-- \| TODO: can we delegate handling Nothing case to process/construct?
specSigner <- case mbSignerPKH of
Nothing -> ExceptT $ pure $ Left CEMScriptTxInResolutionError -- FIXME:
Nothing -> ExceptT $ pure $ Left NoSignerError
Just signerPKH -> pure $ findSkForPKH (actors $ config dappParams) signerPKH
resolutions <- mapM (process cemAction) cs
let resolvedTx = (construct resolutions) {signer = specSigner}
Expand Down

0 comments on commit 8ce26d6

Please sign in to comment.