-
Notifications
You must be signed in to change notification settings - Fork 3.7k
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
[Bug]: Parsing error #19874
Comments
This is the result of doing Maybe we can do something like this for all the places we have this issue, although I don't know if it can cause breakage: - return errorsmod.Wrapf(authz.ErrNoAuthorizationFound, "failed to delete grant with key %s", string(skey))
+ return errorsmod.Wrapf(authz.ErrNoAuthorizationFound, "failed to delete grant with key %X", skey) That way they'd get printed as hex. |
Doesn't really seem like a good long term solution, the grpc client code we use is all auto generated from the proto files in this repository. |
@hg-cardinalchain Could you clarify your concerns? Are you suggesting that we need a human-readable string representation of the key, and because the protobuf clients are auto-generated, they cannot convert the hex into a human-readable format? Also, we know that the key is constructed from: 0x01 | granterAddressLen (1 Byte) | granterAddress_Bytes | granteeAddressLen (1 Byte) | granteeAddress_Bytes | msgType_Bytes. We can write a function that converts this key into a valid UTF-8 encoded string. Can this solve the issue? |
Can I take this issue? |
Sure. A hex string for the key should be fine. The string just needs to be valid UTF-8. |
Is there an existing issue for this?
What happened?
This transaction on the mainnet, https://www.mintscan.io/cosmos/tx/18F9E67C39156EE8C6C39892E22BEC6C4F61121C0C0784C7635F3A53DCB5C888?height=19664155
contains non utf-8 characters in the raw log which causes parsing errors from
protobuf-java
when querying transaction events (cosmos.tx.v1beta1.Service/GetTxsEvent
).the proto docs state
Cosmos SDK Version
0.47.10
How to reproduce?
No response
The text was updated successfully, but these errors were encountered: