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

[Access] Refactor executionNodesForBlockID by encapsulating its parameters into a struct #6499

Conversation

UlyanaAndrukhiv
Copy link
Contributor

@UlyanaAndrukhiv UlyanaAndrukhiv commented Sep 25, 2024

Closes: #6497

Context

This pull request introduces a new struct, ExecutionNodeIdentitiesProvider, which encapsulates the parameters previously passed around multiple functions. This struct is initialized during instance creation and includes fields for executionReceipts, state,preferredENIdentifiers, fixedENIdentifiers and other relevant data.

Changes:

  • Created a new ExecutionNodeIdentitiesProvider struct.
  • Refactored executionNodesForBlockID and related functions to use the new struct instead of individual parameters.
  • Updated relevant unit tests to reflect the changes in function signatures and verify the new implementation.

@codecov-commenter
Copy link

codecov-commenter commented Sep 25, 2024

Codecov Report

Attention: Patch coverage is 41.55844% with 90 lines in your changes missing coverage. Please review.

Project coverage is 41.19%. Comparing base (36f067d) to head (54ffb07).

Files with missing lines Patch % Lines
cmd/access/node_builder/access_node_builder.go 0.00% 48 Missing ⚠️
cmd/observer/node_builder/observer_builder.go 0.00% 35 Missing ⚠️
engine/access/rpc/backend/node_selector.go 0.00% 4 Missing ⚠️
...e/common/rpc/execution_node_identities_provider.go 87.50% 3 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master    #6499      +/-   ##
==========================================
+ Coverage   41.14%   41.19%   +0.04%     
==========================================
  Files        2036     2036              
  Lines      179997   179972      -25     
==========================================
+ Hits        74060    74134      +74     
+ Misses      99720    99613     -107     
- Partials     6217     6225       +8     
Flag Coverage Δ
unittests 41.19% <41.55%> (+0.04%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@UlyanaAndrukhiv UlyanaAndrukhiv marked this pull request as ready for review October 24, 2024 09:47
@Guitarheroua Guitarheroua requested review from zhangchiqing and durkmurder and removed request for zhangchiqing October 24, 2024 09:50
Copy link
Contributor

@Guitarheroua Guitarheroua left a comment

Choose a reason for hiding this comment

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

LGTM

@peterargue peterargue added this pull request to the merge queue Nov 1, 2024
Merged via the queue into onflow:master with commit 0fba2ae Nov 1, 2024
55 checks passed
@peterargue peterargue deleted the UlyanaAndrukhiv/6497-refactor-executionNodesForBlockID branch November 1, 2024 20:44
AndriiDiachuk pushed a commit to The-K-R-O-K/flow-go that referenced this pull request Jan 14, 2025
…refactor-executionNodesForBlockID

[Access] Refactor executionNodesForBlockID by encapsulating its parameters into a struct
@illia-malachyn illia-malachyn restored the UlyanaAndrukhiv/6497-refactor-executionNodesForBlockID branch February 5, 2025 14:50
illia-malachyn pushed a commit that referenced this pull request Feb 5, 2025
…or-executionNodesForBlockID

[Access] Refactor executionNodesForBlockID by encapsulating its parameters into a struct
illia-malachyn added a commit that referenced this pull request Feb 7, 2025
…7-refactor-executionNodesForBlockID"

This reverts commit 1a793e8.
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.

[Access] Refactor executionNodesForBlockID by encapsulating its parameters into a struct
4 participants