Comments (4)
@zoni thanks for the ping! Doing a release for this probably makes sense. @LucioFranco can you take care of that? Maybe now is a good time to document the release process enough that others can also do it?
from tonic.
I encountered this issue as well. AFAICT the problem is this change in the hyper 1.0
upgrade PR:
- tokio-stream = "0.1"
+ h2 = {version = "0.4", optional = true}
+ hyper = {version = "1", features = ["full"], optional = true}
+ hyper-util = { version = ">=0.1.4, <0.2", features = ["full"], optional = true }
+ hyper-timeout = {version = "0.5", optional = true}
+ socket2 = { version = ">=0.4.7, <0.6.0", optional = true, features = ["all"] }
+ tokio = {version = "1", default-features = false, optional = true}
+ tokio-stream = { version = "0.1", features = ["net"] }
tokio-stream
has always been a required dependency, and tokio
is a required dependency of tokio-stream
. But the only feature flag that was enabled was tokio/sync
which works fine on WASM. However, tokio-stream/net
enables tokio/net
, and tonic 0.12
now requires tokio-stream/net
.
It would be good to know whether tokio-stream/net
is actually required at all times, or if it is only needed for the transport
feature flag. I note that tokio-stream
itself is listed under the section of dependencies for the transport
feature flag, so maybe it has always only been used by that feature and just wasn't made optional? If it turns out that tokio/net
is now required for tonic
without feature flags, then that is an undocumented breaking change.
from tonic.
It appears this was already fixed with #1795.
On a wasm32-unknown-unknown
project (which should behave the same as wasm32-wasi
for the purposes of this issue) that has tonic = {version = "0.12", default-features = false, features = ["codegen", "prost"]}
we had a similar problem trying to upgrade from 0.11 to 0.12.
Patching our dependencies to install from git with the above change included, using (in Cargo.toml
):
[patch.crates-io]
tonic = { git = "https://github.com/hyperium/tonic.git", rev = "v0.12.0-12-gaa57ffe" }
...removes the offending tokio/mio dependencies and successfully compiles again.
(Ping @tottoto / @djc as an FYI in case this warrants more explicit calling out in future release notes and/or is worthy of an expedited 0.12.1 patch release)
from tonic.
v0.12.1 has been released.
from tonic.
Related Issues (20)
- Current "uds" example does not compile HOT 3
- Release 0.12.0 HOT 6
- `tonic::transport::Channel` struct is not as safe to clone for parallel use HOT 2
- Error when building excamples
- how to manually fail a client streaming?
- Add debug spans for codec tracing
- test codec::prost::tests::encode_too_big panicks on 32-bit architectures
- Inserting metadata in a test panics with index out of bounds HOT 2
- Upgrading to tonic-reflection 0.12 breaks reflection HOT 2
- use of undeclared crate or module `tonic_reflection` HOT 2
- How does tonic library dynamically set up custom middleware HOT 1
- Naming collisions with std::marker::Sync/Send
- How to make tonic support tls HOT 3
- nit: inconsistent use of crate::Error vs Error in single transport src file
- calling grpc server hosted on cloud run with https fails with transport error HOT 2
- version 0.12.1 causes ClientTlsConfig to explode with invalid CryptoProvider HOT 1
- Configuring Timeout for Graceful Shutdown HOT 1
- How to get grpc-status in Layer?
- Make the TimeoutExpired a public tonic type rather than a transport type
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from tonic.