Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix strange assertion failure, which hides real Block too big problem. #3853

Merged
merged 1 commit into from
Nov 6, 2023

Conversation

TimSheard
Copy link
Contributor

@TimSheard TimSheard commented Nov 6, 2023

Pull request 3828, had a strange failure in the LEDGER rule in the Allegra era. It turns out that an underlying predicate failuure
RealChainPredicateFailure (BlockSizeTooLargeCHAIN 59587 54943) was setting the assertion failure off.
It appears that generating
Block traces ( Test.Cardano.Ledger.Shelley.Generator.Block(genBlockWithTxGen))
occasionally generates blocks that are slightly too big. So this is a failure of the test framework, not the system. We fix this by altering that function to discard, if the generated Block is too big.

This is also the cause of failures in PR 3848. Fixes #3851

Description

Checklist

  • Commit sequence broadly makes sense and commits have useful messages
  • New tests are added if needed and existing tests are updated
  • When applicable, versions are updated in .cabal and CHANGELOG.md files according to the
    versioning process.
  • The version bounds in .cabal files for all affected packages are updated. If you change the bounds in a cabal file, that package itself must have a version increase. (See RELEASING.md)
  • All visible changes are prepended to the latest section of a CHANGELOG.md for the affected packages. New section is never added with the code changes. (See RELEASING.md)
  • Code is formatted with fourmolu (use scripts/fourmolize.sh)
  • Cabal files are formatted (use scripts/cabal-format.sh)
  • hie.yaml has been updated (use scripts/gen-hie.sh)
  • Self-reviewed the diff

@TimSheard TimSheard requested a review from lehins November 6, 2023 20:49
Copy link
Collaborator

@lehins lehins left a comment

Choose a reason for hiding this comment

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

Thank you for figuring this out, @TimSheard !

@lehins lehins enabled auto-merge November 6, 2023 21:59
@lehins lehins merged commit 45f8572 into master Nov 6, 2023
@iohk-bors iohk-bors bot deleted the ts-discard-BlockTooBig branch November 6, 2023 23:10
@lehins lehins changed the title Fix strange assertion failure, which hides real Bock too big problem. Fix strange assertion failure, which hides real Block too big problem. Nov 8, 2023
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.

Property test failure BlockSizeTooLargeCHAIN
2 participants