Checking actixdemo v0.1.0 (/home/erayerdin/Projects/Trash/actixdemo)
warning: unused import: `body::EitherBody`
--> src/shared/middlewares/initial_run.rs:7:5
|
7 | body::EitherBody,
| ^^^^^^^^^^^^^^^^
|
= note: `#[warn(unused_imports)]` on by default
error[E0308]: mismatched types
--> src/shared/middlewares/initial_run.rs:31:15
|
31 | ready(Ok(InitialRunMiddleware { service }))
| ----- ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ expected `Result<InitialRunMiddleware<S>, ()>`, found `Result<InitialRunMiddleware<S>, Error>`
| |
| arguments to this function are incorrect
|
= note: expected enum `Result<_, ()>`
found enum `Result<_, anyhow::Error>`
help: the return type of this call is `Result<InitialRunMiddleware<S>, anyhow::Error>` due to the type of the argument passed
--> src/shared/middlewares/initial_run.rs:31:9
|
31 | ready(Ok(InitialRunMiddleware { service }))
| ^^^^^^------------------------------------^
| |
| this argument influences the return type of `ready`
note: function defined here
--> /home/erayerdin/.rustup/toolchains/stable-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/core/src/future/ready.rs:68:8
|
68 | pub fn ready<T>(t: T) -> Ready<T> {
| ^^^^^
error[E0277]: the trait bound `B: MessageBody` is not satisfied
--> src/shared/middlewares/initial_run.rs:67:24
|
67 | Ok(res.map_into_boxed_body())
| ^^^^^^^^^^^^^^^^^^^ the trait `MessageBody` is not implemented for `B`
|
note: required by a bound in `ServiceResponse::<B>::map_into_boxed_body`
--> /home/erayerdin/.cargo/registry/src/github.com-1ecc6299db9ec823/actix-web-4.3.1/src/service.rs:493:12
|
493 | B: MessageBody + 'static,
| ^^^^^^^^^^^ required by this bound in `ServiceResponse::<B>::map_into_boxed_body`
help: consider further restricting this bound
|
43 | B: 'static + actix_web::body::MessageBody,
| ++++++++++++++++++++++++++++++
error[E0308]: `if` and `else` have incompatible types
--> src/shared/middlewares/initial_run.rs:67:17
|
64 | / if required_setups.len() > 0 {
65 | | Ok(HttpResponse::ServiceUnavailable().body("").into_body())
| | ----------------------------------------------------------- expected because of this
66 | | } else {
67 | | Ok(res.map_into_boxed_body())
| | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ expected `Result<BoxBody, Error>`, found `Result<ServiceResponse, Error>`
68 | | }
| |_____________- `if` and `else` have incompatible types
|
= note: expected enum `Result<BoxBody, _>`
found enum `Result<ServiceResponse, _>`