Skip to content
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

error while upgrading from 0.13 to 0.14 #950

Closed
sam-rusty opened this issue Dec 20, 2024 · 2 comments
Closed

error while upgrading from 0.13 to 0.14 #950

sam-rusty opened this issue Dec 20, 2024 · 2 comments

Comments

@sam-rusty
Copy link

sam-rusty commented Dec 20, 2024

I am trying to update my application from lambda_http from 0.13 to 0.,14 and getting error

the trait bound `LambdaService<Router>: Service<http::Request<lambda_http::Body>>` is not satisfied
the trait `Service<http::Request<aws_lambda_events::encodings::http::Body>>` is implemented for `LambdaService<Router>`
for that trait implementation, expected `aws_lambda_events::encodings::http::Body`, found `lambda_http::Body`

here is my start function

pub async fn start(mut self, name: &str) {
        Self::configure_tracing(name);
        self = self.register_middleware();
        let app = tower::ServiceBuilder::new()
            .layer(axum_aws_lambda::LambdaLayer::default())
            .service(self.router);
        lambda_http::run(app).await.unwrap();
    }

i have tower=0.5.2 and axum-aws-lambda=0.9.0

What do i need to change to get it compiled?

It works when i remove: .layer(axum_aws_lambda::LambdaLayer::default())

Thanks

@sam-rusty sam-rusty changed the title error upgrading from 0.13 to 0.14 error while upgrading from 0.13 to 0.14 Dec 20, 2024
@sam-rusty
Copy link
Author

I guess, I should report this to axum_aws_lambda

Copy link

This issue is now closed. Comments on closed issues are hard for our team to see.
If you need more assistance, please either tag a team member or open a new issue that references this one.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant