Repository navigation
Description
The packages of all Protobuf definitions in the proto folder of on branch main must be renamed from tendermint to cometbft. We intend on making substantial changes to the architecture and interfaces in the coming year and, as such, the protos could diverge substantially from Tendermint Core over time (only across major releases, of course). We also have no intention of remaining compatible with Tendermint Core in future major releases (this is already actually the case with our v0.37 release). As such, it makes very little sense, from a product perspective, to continue producing interface/data structure changes for Tendermint Core.
Having our proto package as cometbft will make publishing these protos to registries, e.g. https://buf.build/cometbft/cometbft, easier for us and for integrators who consume them (especially once we version our protos, in #95).
e.g.
| package tendermint.types; |
must be renamed to:
package cometbft.types;This includes regenerating all of the Go code and resolving any import errors.
Branches v0.37.x and v0.34.x will stay as they are:
- in order to minimize disruption in the ecosystem
- all protos in those branches are reused verbatim from the Tendermint Core repo
Further, we cannot do this for the v0.34.x branch because we would be breaking the message URLs associated with these messages, meaning CometBFT would potentially be incompatible with Tendermint Core, meaning that networks would need to perform a coordinated upgrade to CometBFT. Ideally we want our first v0.34-series release to be a drop-in replacement, so that a coordinated upgrade isn't necessary.
Metadata
Metadata
Assignees
Labels
Type
Projects
- StatusShow more project fieldsDone
Activity
[-]Rename Protobuf packages from `tendermint` -> `cometbft`[/-][+]proto: Rename packages from `tendermint` -> `cometbft`[/+]cason commentedon Jan 31, 2023
Some renaming, mostly on comments and documentation, was part of #224.
spec: migrate v0.7.1. into v0.34 (#9262)
mzabaluev commentedon Mar 6, 2023
There are gRPC services defined in these files:
abci/types.protoABCIApplicationrpc/grpc/types.protoBroadcastAPIChanging the package name will result in changing the gRPC endpoints for these services as used by the generated code.
Do we want to go forward with it as part of this renaming, or should I keep these packages in the
tendermintnamespace?thanethomson commentedon Mar 7, 2023
We have no intention of keeping the
tendermintnamespace for anything Protobuf- or gRPC-related from our v0.38 release onwards. We also intend on implementing a full gRPC interface to the node ASAP, as per #81 (@mzabaluev, if you want, this is something you could take on once #94 and #95 are done).tac0turtle commentedon Mar 7, 2023
It would be good to talk to users and get a list of what this breaks. From my understanding this could break ibc tendermint clients and potentially apps in cosmos that use these types would need to migrate.
We can only do so much from our end in the sdk.
mzabaluev commentedon Mar 7, 2023
Pet peeve time: while we are at breaking things, could we rename
BroadcastAPI? I mean, it is an API, but no need to state the obvious in the naming that gets emitted in all kinds of code and resource names, and in the annoyingly caps-intensive way (in some hypothetical code generator that converts to snake_case with stupid rules, that might end up asbroadcast_a_p_i).thanethomson commentedon Mar 7, 2023
Yeah we're definitely going to try to solicit as much feedback as possible. My recommendation to @mzabaluev has been to do this work in a feature branch (feature/proto-upgrade, which is currently based on the vote extensions feature branch) so we can choose when exactly to incorporate this.
My understanding at present is that this primarily breaks:
Anyfields) that embeds the full path to the Protobuf type.github.com/cometbft/cometbft/proto/tendermint(where this would eventually change togithub.com/cometbft/cometbft/apiafter proto: Implement versioning #95).What other kinds of breakage do folks expect?
Wire-level encoding/decoding should be 100% compatible, except if you've somehow embedded type names in your encoded data.
It seems to me as though while working on #81 would be the best time to do this, would it not?
thanethomson commentedon Mar 7, 2023
It would also be interesting to investigate whether it's possible to offer both packages' protos simultaneously.
For instance, could we internally switch to using
cometbftpackage protos and their generated code, while still offeringtendermintprotos (no longer hooked into our code anywhere) for external consumers, with thesetenderminttypes being wire-level compatible with theircometbftcounterparts?tac0turtle commentedon Mar 7, 2023
for sdk i thought of a way we can avoid the breakage but allow you to break, i still need to test.
For go the main thing we care about is the option_go_package call because that defines how we import the generated files, but the proto url is what matters for state compatibility, we already have the idea to generate our own protos (this idea was around before the rename). We would keep the same proto urls and rename the option_go_package names to cosmos-sdk imports. That way things stay the same for us but allow you to break for future users
sergio-mena commentedon Jul 5, 2023
Moved to Q3. It is part of
v0.39.xrelease plan tracking issuesergio-mena commentedon Sep 26, 2023
After examination with @mzabaluev , we consider all these activities complete. The final feature branch merge into
mainis tracked in the parent issue. Reason: the feature branch is also being used for versioning.Merge pull request cometbft#94 from osmosis-labs/mergify/bp/osmo-v25/…