-
Notifications
You must be signed in to change notification settings - Fork 87
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
Compile errors of v0.41.0
while only serde
feature enabled
#741
Comments
Thanks @riversyang for laying out the problem so clearly. Yes, it’s the right place to discuss! For a bit of contextAfter implementing ProtoJSON-compatible Possible remedyYes! As you said and from what I see, those two impls look unnecessary:
Assuming no objections, this should work, and we can avoid changing A side questionIIRC, you were also using the |
Thanks for the quick response, @Farhad-Shabani! Regarding the As for the Lastly, to clarify, the |
in near ibc maybe you can use borsh😃 |
relate this relate no-std : cosmos/ics23#155 i working this, aim to enable ics23 serde to support no -std |
about issue: #753 |
Check #763, please
Opened #764 I don't know any other ways in |
oh, so many issues. what issue to track when it will be fixed? |
last working commit 2403dc3 . why not to revert breaking change until it fixed? |
Basically "restoring no_std compatibility" for ibc-proto-rs (reopened cosmos/ibc-proto-rs#98). By which, then the
There are projects dependent on ibc-proto-rs >= v0.32 |
Closes: #156 Addresses the `no_std` compatibility issue with `serde` feature in `ibc-rs`. This is caused by the recent implementation of ProtoJSON serialization and deserialization [0] for the `ics23` Protobuf definitions using `pbjson`, and then re-exporting the ics23 type [1] in `ibc-proto-rs`. Some of our users by then (starting from IBC-rs v0.41.0) are experiencing compilation errors. [2] To meet this immediate need [3] and the lack of activity in the `pbjson` crate for months, we have taken the initiative to feature `no_std` support in the `informalsystems-pbjson` crate and have it published. [0] #146 [1] cosmos/ibc-proto-rs#92 [2] cosmos/ibc-rs#741 [3] cosmos/ibc-proto-rs#98 (comment) --- * feat: enable no_std support for pbjson * fix: get serde feature work with no-std * deps: use informalsystems-pbjson v0.6.0 * deps: use informalsystems-pbjson v0.6.0
Problem Summary
During the integration of
ibc-rs v0.41.0
into near-ibc, I got compile errors in the following places:ibc-rs/crates/ibc/src/applications/transfer/packet.rs
Lines 13 to 25 in 349d7f5
ibc-rs/crates/ibc/src/core/ics02_client/events.rs
Lines 135 to 151 in 349d7f5
In
near-ibc
project, we only need to enableborsh
andserde
features ofibc-rs
. So I checked source code and found that this is because the definition ofibc_proto::ibc::applications::transfer::v2::FungibleTokenPacketData
andibc_proto::google::protobuf::Any
inibc-proto-rs v0.32.0
were defined as:#[cfg_attr(feature = "std", derive(::serde::Serialize, ::serde::Deserialize))]
I have removed the feature condition from the derive statement for now, which allowed the code to compile. But I'm not sure whether I should commit this issue to
ibc-proto-rs
.Anyway, I believe it would be worth discussing the issue in the
ibc-rs
implementation. It is important to determine whether the current implementation of the two mentioned places is necessary and appropriate.The text was updated successfully, but these errors were encountered: