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

Refactor the ChainEndpoint trait to expose the light client functionality directly #2548

Closed
1 of 5 tasks
romac opened this issue Aug 12, 2022 · 0 comments · Fixed by #2529
Closed
1 of 5 tasks

Refactor the ChainEndpoint trait to expose the light client functionality directly #2548

romac opened this issue Aug 12, 2022 · 0 comments · Fixed by #2529
Milestone

Comments

@romac
Copy link
Member

romac commented Aug 12, 2022

Summary

Refactor the ChainEndpoint trait to expose the light client functionality directly instead of via a getter for a LightClient.

Problem Definition

The chain runtime is too coupled to the light client (the former should ideally not need to know about the latter). By decoupling the two we could simplify the runtime initialization code and keep a cleaner SoC.

Proposal

Instead of exposing a getter for the LightClient trait, the ChainEndpoint trait should now define the two methods verify_header and check_misbehaviour directly.

Acceptance Criteria

As above.


For Admin Use

  • Not duplicate issue
  • Appropriate labels applied
  • Appropriate milestone (priority) applied
  • Appropriate contributors tagged
  • Contributor assigned/self-assigned
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
1 participant