theam / aws-lambda-haskell-runtime

⚡Haskell runtime for AWS Lambda
https://theam.github.io/aws-lambda-haskell-runtime/
Other
269 stars 48 forks source link

`StandaloneLambdaResponseBody` seems impossible to construct #108

Open tysonzero opened 2 years ago

tysonzero commented 2 years ago

I'm on an older version of this library using runLambda, StandaloneLambdaResult and toStandaloneLambdaResponse.

Now that I'm upgrading to a newer library version, I have no clue how to keep my code working. StandaloneLambdaResponseBody seems impossible to construct, and I need it for the StandaloneLambdaResult constructor of LambdaResult.

NickSeagull commented 2 years ago

Hey! Thanks for reporting :)

Have you tried doing a toStandaloneLambdaResponse <yourResult>? There is a type class ToStandaloneLambdaResponseBody that will make ByteStrings/Texts or any type that implements ToJSON returnable from your handler

tysonzero commented 2 years ago

toStandaloneLambdaResponse isn't exported by any public modules anymore.

NickSeagull commented 2 years ago

Woops! Let's keep the conversation going in #109