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
I'm doing a proof-of-concept of wrapping a lambda_runtime::Handler into another one. The idea is that I could then add and chain capabilities with a nice interface.
However, I'm facing an issue in how I call the actual function, since the Handler trait has a synchronous function call() that returns a Future. That means that I cannot await the function's call and then do something with the result. How could I handle that?
Hey folks!
I'm doing a proof-of-concept of wrapping a
lambda_runtime::Handler
into another one. The idea is that I could then add and chain capabilities with a nice interface.However, I'm facing an issue in how I call the actual function, since the
Handler
trait has a synchronous functioncall()
that returns a Future. That means that I cannot await the function's call and then do something with the result. How could I handle that?Here's the POC I currently have, with the problem highlighted: https://gist.github.com/nmoutschen/5a264d1d2d246d265517962ff91cba8c#file-wrap_handler-rs-L33
If I wrap the call into an
async {}
block, I then get the following error:The text was updated successfully, but these errors were encountered: