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

[Proto] Support Cosmos scalar type definitions #1211

Open
byte-bandit opened this issue Jan 23, 2024 · 2 comments
Open

[Proto] Support Cosmos scalar type definitions #1211

byte-bandit opened this issue Jan 23, 2024 · 2 comments
Assignees
Labels
good first issue Good for newcomers paloma

Comments

@byte-bandit
Copy link

CosmosSDK released support for scalar type definitions: cosmos/cosmos-sdk#9933

They make working with custom types much easier for us, and support for other languages than Go isn't needed in our case. The gravity module already makes use of them, but our compiler doesn't actually apply the needed changes, meaning the underlying datatypes are still native typed.

We should upgrade this some time.

Opening this issue to keep track of it.

@byte-bandit byte-bandit self-assigned this Jan 23, 2024
@byte-bandit byte-bandit added the good first issue Good for newcomers label Apr 16, 2024
@byte-bandit byte-bandit assigned maharifu and unassigned byte-bandit May 20, 2024
@maharifu
Copy link

Is the implementation of the scalar types really finished, though? It seems it adds the scalar types annotations, but doesn't change the generators, meaning we still get the underlying native types. That PR does not change the resulting data types.

For instance, the latest version of cosmos still has string address fields even though they have the scalar type annotation in the proto definition. I compiled the protos from the HEAD of the repo and got the same results. Upgrading our proto compiler also yields the same.

We could still add the annotations, but we don't seem to get much benefit from it now.

@byte-bandit
Copy link
Author

Nah, this was really meant as a tracking ticket so I wouldn't forget about this. I don't think they'll update their generators any time soon tbh. Feel free to skip this one.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Good for newcomers paloma
Projects
None yet
Development

No branches or pull requests

2 participants