Skip to content

Conversation

@f-f
Copy link
Collaborator

@f-f f-f commented Dec 2, 2025

Description

Fix #5447, fix #5448

Checklist

  • Commits in meaningful sequence and with useful messages.
  • Tests added or updated when needed.
  • CHANGELOG.md files updated for packages with externally visible changes.
    NOTE: New section is never added with the code changes. (See RELEASING.md).
  • Versions updated in .cabal and CHANGELOG.md files when necessary, according to the
    versioning process.
  • Version bounds in .cabal files updated when necessary.
    NOTE: If bounds change in a cabal file, that package itself must have a version increase. (See RELEASING.md).
  • Code formatted (use scripts/fourmolize.sh).
  • Cabal files formatted (use scripts/cabal-format.sh).
  • CDDL files are up to date (use scripts/gen-cddl.sh)
  • hie.yaml updated (use scripts/gen-hie.sh).
  • Self-reviewed the diff.

@f-f
Copy link
Collaborator Author

f-f commented Dec 2, 2025

@lehins this is just a draft because it doesn't build yet: I am not sure how I should convince GHC to accept my constraints on test code:

  • the Imp.spec for Dijkstra is not happy because Couldn't match type DijkstraMempoolPredFailure with DijkstraLedgerPredFailure
  • Dijkstra now wants the Mempool failure in ApplyTx, and the mismatch is coming from Conway Imp test, as Conway has the Ledger failure as entrypoint

I suppose the issue is that the Imp tests for next eras call the ones for the previous era, so probably there is an easy way to rearrange this to have it not complain, but I am not seeing it atm.

@f-f f-f force-pushed the f-f/5447 branch 3 times, most recently from 07b468a to b80b176 Compare December 5, 2025 11:13
@f-f f-f marked this pull request as ready for review December 5, 2025 11:13
@f-f f-f requested a review from a team as a code owner December 5, 2025 11:13

describe "Mempool" $ do
let
submitFailingMempoolTx ::
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

these type signatures are needed to make the compiler infer correctly the injectFailure below

exampleTxDijkstra
exampleDijkstraGenesis

mkLedgerExamples ::
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We do need a new copy of this one unfortunately, because of the wrapping of the Ledger failure into the Mempool failure

f-f added 2 commits December 5, 2025 18:05
To get there we need to move the `ApplyTxError era` type to be a
data family in the ApplyTx class
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Create AllInputsAreSpent predicate failure for MEMPOOL rule Swap Mempool/Ledger predicate failure

3 participants