Skip to content

fix: use next epoch for pending balance/consolidations processing - #7053

Merged
ensi321 merged 4 commits into
electra-fork-rebasejul30from
devnet3
Aug 28, 2024
Merged

fix: use next epoch for pending balance/consolidations processing#7053
ensi321 merged 4 commits into
electra-fork-rebasejul30from
devnet3

Conversation

@g11tech

@g11tech g11tech commented Aug 27, 2024

Copy link
Copy Markdown
Contributor

devnet3 branch

@g11tech
g11tech requested a review from a team as a code owner August 27, 2024 15:28
wemeetagain
wemeetagain previously approved these changes Aug 27, 2024
nflaig
nflaig previously approved these changes Aug 27, 2024
@codecov

codecov Bot commented Aug 27, 2024

Copy link
Copy Markdown

Codecov Report

Attention: Patch coverage is 0% with 4 lines in your changes missing coverage. Please review.

Project coverage is 49.37%. Comparing base (ed18ff0) to head (02b328b).
Report is 2 commits behind head on electra-fork-rebasejul30.

Additional details and impacted files
@@                     Coverage Diff                      @@
##           electra-fork-rebasejul30    #7053      +/-   ##
============================================================
- Coverage                     49.39%   49.37%   -0.03%     
============================================================
  Files                           589      589              
  Lines                         39233    39233              
  Branches                       2247     2243       -4     
============================================================
- Hits                          19378    19370       -8     
- Misses                        19814    19822       +8     
  Partials                         41       41              

* TODO Electra: Update ssz library to support batch push to `pendingBalanceDeposits`
*/
export function processPendingBalanceDeposits(state: CachedBeaconStateElectra, cache: EpochTransitionCache): void {
const nextEpoch = state.epochCtx.epoch + 1;

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

I really like the name upcomingEpoch made by @matthewkeil for processEpoch code in his async shuffling PR #6938

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

yea name is good but i think good to be closer to naming used in specs, though not a strong opinion

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

+1 on following spec naming, I think we should have a good reason if we wanna deviate from terms used in spec.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Yeah, if we really have a problem with the naming, we should aim to update it in the spec instead. Deviating off standards create more context loss for new people reading our code IMO.

twoeths
twoeths previously approved these changes Aug 28, 2024
@matthewkeil
matthewkeil force-pushed the electra-fork-rebasejul30 branch from aa653e2 to ed18ff0 Compare August 28, 2024 08:35
@g11tech
g11tech dismissed stale reviews from twoeths, nflaig, and wemeetagain via b9f0b50 August 28, 2024 12:48
],
// TODO Electra: Review this test in the next spec test release
skippedTests: [/incorrect_not_enough_consolidation_churn_available/],
skippedTests: [/incorrect_not_enough_consolidation_churn_available/, /^deneb\/light_client\/sync\/.*electra_fork.*/],

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

I believe /incorrect_not_enough_consolidation_churn_available/ can be removed since it was fixed after alpha.3

* TODO Electra: Update ssz library to support batch push to `pendingBalanceDeposits`
*/
export function processPendingBalanceDeposits(state: CachedBeaconStateElectra, cache: EpochTransitionCache): void {
const nextEpoch = state.epochCtx.epoch + 1;

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

+1 on following spec naming, I think we should have a good reason if we wanna deviate from terms used in spec.

Comment thread packages/beacon-node/test/spec/utils/specTestIterator.ts Outdated
@ensi321
ensi321 merged commit 03f7396 into electra-fork-rebasejul30 Aug 28, 2024
@ensi321
ensi321 deleted the devnet3 branch August 28, 2024 18:42
@wemeetagain

Copy link
Copy Markdown
Member

馃帀 This PR is included in v1.22.0 馃帀

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.

6 participants