You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
With the release of v0.12.0, it is no longer possible to use error types defined externally to your own crate. This is caused by the inclusion of #897.
Example:
// Works in both v0.11.3 and v0.12.0typeError = Box<dyn std::error::Error>;// Works in v0.11.3 but not in v0.12.0// type Error = std::io::Error;// Works in v0.11.3 but not in v0.12.0// type Error = anyhow::Error;// Works in neither v0.11.3 nor v0.12.0// type Error = lambda_runtime::Diagnostic<'static>;asyncfnhandler(_event: lambda_runtime::LambdaEvent<()>) -> Result<(),Error>{Ok(())}#[tokio::main]asyncfnmain(){
lambda_runtime::run(lambda_runtime::service_fn(handler)).await.unwrap();}
Note that it is not possible to implement Into<Diagnostic<'a>> yourself for any of these types because of the orphan rules.