Lightclient module structuring and internal keeper usage #6186
Labels
change: api breaking
Issues or PRs that break Go API (need to be release in a new major version)
needs discussion
Issues that need discussion before they can be worked on
type: code hygiene
Clean up code but without changing functionality or interfaces
type: refactor
Architecture, code or CI improvements that may or may not tackle technical debt.
Summary
Historically light client modules have had a very open ended code structure with most if not all code existing within
package types
or since ibc-go/v7 within the root of the lightclient module, e.g.package tendermint
.Since #5806 and decoupling client encoding from routing within ibc-go there is now a more unrestricted opportunity to provide more structure and code organisation to lightclient modules - as we do not rely on all functionality being tightly coupled with the client state type/interface implementation.
See: #5806 (comment)
Problem Definition
Currently, there is little to no code organisation within the majority of lightclient modules. The 08-wasm module contains a similar structure, reminiscent to that of a regular sdk module and has seen much improvements and benefits from the refactor linked above.
With the refactor we introduced an
internal/keeper
to 07-tendermint with intensions for this to be useful for things such as msg server execution, in particular governance authorised requests such as changing client state parameters.Proposal
Explore some paths for providing a simple and organised structure for lightclient modules.
internal/keeper
for state management. For example, usage ofstoreProvider
forget/set
operations of client/consensus states and metadata.package types
as they were previously.For Admin Use
The text was updated successfully, but these errors were encountered: