-
Notifications
You must be signed in to change notification settings - Fork 1k
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
tonic_web: NamedService bound on enable() required #1177
Comments
Same here. |
I believe https://github.com/hyperium/tonic/blob/master/examples/src/grpc-web/server.rs#L42 should work for you? |
Thanks @LucioFranco, works like a charm! I assume documentation needs to be fixed... |
It worked for me as well, though I had to add the Cors layer manual now that I cannot use |
Ah yup those docs need to be updated! @softdevca yeah the cors stuff got removed iirc, you can check the PRs we made for tonic-web to see the background. |
Gonna close this since I think we got this all resolved. |
Bug Report
It was proposed to remove the
NamedService
bound oftonic_web::enable()
in issue #1115. This change was accepted but it breaks adding theenable
'd service to a Tonic server.Issue #1174 was briefly filed and closed with a work around.
Version
Platform
MacOS 13.0.1 on M1 Pro, rust 1.65.0
Pop OS Linux on AMD, rust 1.65.0
Description
The standard example below will not compile because
add_service
requires theNamedService
trait andtonic_web::enable
no longer provides it.The text was updated successfully, but these errors were encountered: