Skip to content
This repository has been archived by the owner on Nov 28, 2023. It is now read-only.

Update axum requirement from 0.6.20 to 0.7.1 #76

Update axum requirement from 0.6.20 to 0.7.1

Update axum requirement from 0.6.20 to 0.7.1 #76

GitHub Actions / clippy failed Nov 27, 2023 in 0s

clippy

4 errors

Details

Results

Message level Amount
Internal compiler error 0
Error 4
Warning 0
Note 0
Help 0

Versions

  • rustc 1.74.0 (79e9716c9 2023-11-13)
  • cargo 1.74.0 (ecb9851af 2023-10-18)
  • clippy 0.1.74 (79e9716 2023-11-13)

Annotations

Check failure on line 1206 in src/bin/api.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

the trait bound `fn() -> impl std::future::Future<Output = Hello<'static>> {root}: axum::handler::Handler<_, _>` is not satisfied

error[E0277]: the trait bound `fn() -> impl std::future::Future<Output = Hello<'static>> {root}: axum::handler::Handler<_, _>` is not satisfied
    --> src/bin/api.rs:1206:25
     |
1206 |         .route("/", get(root))
     |                     --- ^^^^ the trait `axum::handler::Handler<_, _>` is not implemented for fn item `fn() -> impl std::future::Future<Output = Hello<'static>> {root}`
     |                     |
     |                     required by a bound introduced by this call
     |
help: trait impls with same name found
    --> /home/runner/.cargo/registry/src/index.crates.io-6f17d22bba15001f/axum-0.6.20/src/handler/mod.rs:198:1
     |
198  | impl<F, Fut, Res, S, B> Handler<((),), S, B> for F
     | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
...
257  | all_the_tuples!(impl_handler);
     | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
...
265  | impl<T, S, B> Handler<private::IntoResponseHandler, S, B> for T
     | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
     = note: perhaps two different versions of crate `axum` are being used?
     = help: the following other types implement trait `axum::handler::Handler<T, S>`:
               <axum::handler::Layered<L, H, T, S> as axum::handler::Handler<T, S>>
               <axum::routing::MethodRouter<S> as axum::handler::Handler<(), S>>
note: required by a bound in `axum::routing::get`
    --> /home/runner/.cargo/registry/src/index.crates.io-6f17d22bba15001f/axum-0.7.1/src/routing/method_routing.rs:385:1
     |
385  | top_level_handler_fn!(get, GET);
     | ^^^^^^^^^^^^^^^^^^^^^^---^^^^^^
     | |                     |
     | |                     required by a bound in this function
     | required by this bound in `get`
     = note: this error originates in the macro `impl_handler` which comes from the expansion of the macro `top_level_handler_fn` (in Nightly builds, run with -Z macro-backtrace for more info)

Check failure on line 1172 in src/bin/api.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

the trait bound `tower_http::services::ServeDir: hyper::service::Service<axum::http::Request<axum::body::Body>>` is not satisfied

error[E0277]: the trait bound `tower_http::services::ServeDir: hyper::service::Service<axum::http::Request<axum::body::Body>>` is not satisfied
    --> src/bin/api.rs:1172:37
     |
1172 |     Router::new().nest_service("/", get_service(ServeDir::new("./assets")))
     |                                     ^^^^^^^^^^^ the trait `hyper::service::Service<axum::http::Request<axum::body::Body>>` is not implemented for `tower_http::services::ServeDir`
     |
     = help: the trait `hyper::service::Service<hyper::Request<ReqBody>>` is implemented for `tower_http::services::ServeDir<F>`

Check failure on line 1172 in src/bin/api.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

the trait bound `tower_http::services::ServeDir: hyper::service::Service<axum::http::Request<axum::body::Body>>` is not satisfied

error[E0277]: the trait bound `tower_http::services::ServeDir: hyper::service::Service<axum::http::Request<axum::body::Body>>` is not satisfied
    --> src/bin/api.rs:1172:49
     |
1172 |     Router::new().nest_service("/", get_service(ServeDir::new("./assets")))
     |                                     ----------- ^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `hyper::service::Service<axum::http::Request<axum::body::Body>>` is not implemented for `tower_http::services::ServeDir`
     |                                     |
     |                                     required by a bound introduced by this call
     |
     = help: the trait `hyper::service::Service<hyper::Request<ReqBody>>` is implemented for `tower_http::services::ServeDir<F>`
note: required by a bound in `axum::routing::get_service`
    --> /home/runner/.cargo/registry/src/index.crates.io-6f17d22bba15001f/axum-0.7.1/src/routing/method_routing.rs:282:1
     |
282  | top_level_service_fn!(get_service, GET);
     | ^^^^^^^^^^^^^^^^^^^^^^-----------^^^^^^
     | |                     |
     | |                     required by a bound in this function
     | required by this bound in `get_service`
     = note: this error originates in the macro `top_level_service_fn` (in Nightly builds, run with -Z macro-backtrace for more info)

Check failure on line 6 in src/bin/api.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

unresolved import `axum::Server`

error[E0432]: unresolved import `axum::Server`
 --> src/bin/api.rs:6:26
  |
6 | use axum::{Json, Router, Server};
  |                          ^^^^^^
  |                          |
  |                          no `Server` in the root
  |                          help: a similar name exists in the module: `serve`