Skip to content

feat(internal/client): BlockImport implementation for Client #4647

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

Open
wants to merge 172 commits into
base: development
Choose a base branch
from

Conversation

dimartiro
Copy link
Contributor

@dimartiro dimartiro commented Apr 7, 2025

Changes

Implements BlockImport interface methods CheckBlock and BlockImport in internal/client Client structure.
Also adds all dependencies and helper functions

Summary

  • Implements CheckBlock method
  • Implements ImportBlock method
    • Implement prepareBlockStorageChanges
    • Implement applyBlock method
  • Modify generics to add Executor and ConstructRuntimeApi
  • Introduce ApiExt, ConstructRuntimeApi and ProvideRuntimeApi interfaces
  • Update and add new tests

Tests

make test

IMO it will be better to finish the rest of the tasks and code an integration test for the ImportBlock instead of unit testing it

Issues

Closes: #4458

@dimartiro dimartiro linked an issue Apr 7, 2025 that may be closed by this pull request
@dimartiro dimartiro force-pushed the diego/block-import-impl branch from adbf0d4 to f9f5ca2 Compare April 10, 2025 13:44
Base automatically changed from diego/block-import to development April 10, 2025 13:48
@dimartiro dimartiro marked this pull request as ready for review April 15, 2025 14:18
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.

Implement BlockImport interface for Client type
1 participant