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

1678: epoch_stake missing entries #1796

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

Cmdv
Copy link
Contributor

@Cmdv Cmdv commented Jul 30, 2024

Description

This PR fixes #1678

Currently trying to log out the slice function as it's not behaving correctly

Checklist

  • Commit sequence broadly makes sense
  • Commits have useful messages
  • New tests are added if needed and existing tests are updated
  • Any changes are noted in the changelog
  • Code is formatted with fourmolu on version 0.10.1.0 (which can be run with scripts/fourmolize.sh)
  • Self-reviewed the diff

Migrations

  • The pr causes a breaking change of type a,b or c
  • If there is a breaking change, the pr includes a database migration and/or a fix process for old values, so that upgrade is possible
  • Resyncing and running the migrations provided will result in the same database semantically

If there is a breaking change, especially a big one, please add a justification here. Please elaborate
more what the migration achieves, what it cannot achieve or why a migration is not possible.

@Cmdv Cmdv force-pushed the 1678-epoch_stake-missing-entries branch 2 times, most recently from 4775489 to 9644c31 Compare August 2, 2024 13:15
@Cmdv Cmdv force-pushed the 1678-epoch_stake-missing-entries branch from 9644c31 to 13838d6 Compare August 2, 2024 13:16
@Cmdv Cmdv force-pushed the 1678-epoch_stake-missing-entries branch from 6f545af to 0242576 Compare August 13, 2024 11:41
@Cmdv Cmdv marked this pull request as ready for review August 13, 2024 12:54
@Cmdv Cmdv requested a review from a team as a code owner August 13, 2024 12:54
Copy link
Contributor

@kderme kderme left a comment

Choose a reason for hiding this comment

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

This looks good. I'll make some modifications for the isMigration case and we can merge.

assertEpochStake dbSync 5
blks <- fillUntilNextEpoch interpreter mockServer
assertBlockNoBackoff dbSync (fromIntegral $ length blks)
-- There are 10 delegations in genesis
Copy link
Contributor

Choose a reason for hiding this comment

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

Is this comment correct or is the old comment wrong about genesi?

Copy link
Contributor Author

@Cmdv Cmdv Aug 14, 2024

Choose a reason for hiding this comment

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

it can be removed. I think in the previous implementation, by the time the assertEpochStake was called the epoch 2 wouldn't have been inserted. This is why I changed the tests to check each epoch 1 + 2 separately

@Cmdv
Copy link
Contributor Author

Cmdv commented Aug 14, 2024

I'll make some modifications for the isMigration case and we can merge

What modification does it need? I'm happy to make the changes or discuss

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.

epoch_stake missing entries in not dense epoch
2 participants