Remix.run Logo
raw_anon_1111 8 hours ago

We also have "dev mode" which let's you to test/debug your lambdas locally without re-deployment

As does both SAM and the CDK.

https://docs.aws.amazon.com/cdk/v2/guide/testing-locally-get...

But this is 2026. You should be deploying Docker containers to Lambda and those are really easy to test locally

SamuelAdams 3 hours ago | parent [-]

Docker has a large cold start time usually, sometimes it can take up to 10 seconds for a dockerized Python lambda to invoke. Are there solutions for that, that include docker?

raw_anon_1111 2 hours ago | parent [-]

Fair point, I’m working on a project now that doesn’t require responsiveness - it’s not user facing. We were burned so bad by Lambda cold starts for user facing lambdas that were backing websites we said forget it and just used ECS/fargate. This is my go to template - I didn’t write it. I found it 7 years ago.

https://github.com/1Strategy/fargate-cloudformation-example/...

You just update the parameter for your container image and redeploy.

Of course you have provisioned concurrency that can help.

But the easiest way to test Python lambdas locally is just to run it like any other Python script and call your event handler with the event you want to test