-
Notifications
You must be signed in to change notification settings - Fork 9
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
light-clients: update revision number for cf-guest and cf-solana to 1 #392
Conversation
I don’t follow, why do we need this? |
well we used revision number as 1 everywhere since ibc-go used to omit it if it is 0. In our case it doesnt really matter what we use a revision number but i think, using 1 everywhere seems like a good option to maintain backward compatibility. |
Right, but my point is why are we changing the revision number? Why can’t it be zero? |
if we make it to 0, we wouldnt be able to establish a connection with cosmos since it omits the field if the value is 0. |
Yes, that’s how protobuf works. In proto3 zero fields are not encoded but then when decoding zero is implied. So Cosmos should decode it as zero just fine. |
but apparently it doesnt, i am not sure why. When we were having revision height as 0, we were getting missing field issue on ibc-go. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
OK, though now the rollout is potentially tricky, no? This needs to be updated in the solana-ibc and on Picasso at the same time, no?
well no, since picasso uses cf-guest from |
But that uses this cf-guest as dependency, no? |
the cf-guest light client on picasso doesnt implement |
LGTM |
This is to increase compatibility with other libraries which fail to
properly decode proto3 message with missing revision number field
(missing fields should be decoded as zero in proto3).