-
Notifications
You must be signed in to change notification settings - Fork 3.8k
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
Restructure x/ibc layout #6945
Comments
Agreed with all of these suggestions, except that I'm not sure about application modules. If a chain ends up having several IBC application modules, should they really all be housed under |
my main interest in having I guess we could have I see your point though, whichever way is fine with me. I'd just like to be deliberate and account for a future in which we might have as many IBC application modules as we have modules in |
If this is true then I agree with you, it's this point I'm not sure about - e.g. almost every module uses I guess these aren't mutually exclusive, though - I'm fine with having an |
cc/ @fedekunze @AdityaSripal thoughts? |
The proposal looks good. I don't know how easy the refactor is going to be. Ideally, we should have a strategy to migrate the submodules/pkgs in a specific order |
maybe start by moving the light client implementations to their own folder at the top level of |
should we restructure the |
This can be done asynchronously, but we should do the rest at some synchronous time to avoid too much PR rebase chaos. Let's do this at the end of milestone 21 completion or at least a point when there are no PRs outstanding. |
Realizing we arrived at roughly similar breakdown in discussing reorging the spec today. Only difference in the spec discussion was splitting |
@fedekunze Yes, would be great to align with how we structure other proto files in the sdk. Though not 100% parity is required, as In general the proto layout should not differ too much from the corresponding go source code layout, as its often the case that you will want generated code to be in similar go packages to their proto package names. |
Makes sense to me. Short term I don't think it'll be possible, at least when it comes to the notion of ports and capabilities since the connection and channel handshakes rely on this SDK specific implementation. I think another issue related to this is IBC's reliance on Tendermint being the self client. I assume non SDK go code wanting to use IBC would likely do so because they don't want to use Tendermint (path of least resistance when using Tendermint is using the SDK). With all this in mind, separation of
cc/ @AdityaSripal |
I think it makes sense to tackle this before a code freeze. It should just be the latest issue tackled |
I think the ICS spec versions should probably directly correspond to how we version our proto definitions, see #7338. If anyone has any strong opinions here it'd be good to voice them sooner than later. Might be worthwhile coming to a final decision at next Tuesday's IBC Core call |
I think we should prioritize this to get API stability for the release candidates |
Maybe we can do it after the upgrade pr is merged? |
Summary
Create a logical flow of directory layout for ibc related files.
Problem Definition
When I first started going through ibc material, I found the layout slightly confusing as I documented in #6092. I think there is still some improvements that can be made and if addressed before launch will probably prevent some headaches down the line. To me there is 3 main parts of the SDK's IBC implementation: core ibc, light client implementations, application modules.
A user of IBC maybe be interested in only one of those categories and currently storing core ibc and light client implementations together can probably add a bit of confusion. Ideally onboarding onto ibc is as painless as possible.
Furthermore while the move from
x/ibc/20-transfer
tox/ibc-transfer
was an improvement, it feels unsustainable for SDK housed ibc application modules to all live at the top level ofx/
Proposal
Create a file structure as follows:
specific naming could be adjusted as necessary. I prefer
core
overtao
because it is more natural to any outsider coming in without previous ibc experience.this also splits up the spec nicely. The recent client handling changes to tendermint @AdityaSripal has been making would feel a little weird if the
x/ibc/spec
had core and client specific implementation details.Pros:
x/ibc
(besides simapp related stuff ofc)x/ibc/light-clients/tendermint
,x/ibc/core/etc
,x/ibc/applications/transfer
Cons:
For Admin Use
The text was updated successfully, but these errors were encountered: