Summary
This release adds a change to the idempotency utility, expiring in-progress executions if the Lambda function times out halfway through.
The new feature requires no code changes. However, if you're using just the idempotent_function
decorator, you will want to register the Lambda context on your handler to take advantage of this feature:
To prevent against extended failed retries when a Lambda function times out, Powertools now calculates and includes the remaining invocation available time as part of the idempotency record. If a second invocation happens after this timestamp, and the record is marked as INPROGRESS
, we will execute the invocation again as if it was in the EXPIRED
state (e.g, expire_seconds
field elapsed).
We also enabled static analysis (mypy) on the new statically typed documentation snippets - big thanks to @VictorCovalski for spotting one issue in Event Handler that later led to 50 other fixes.
Oh! Did I also tell you we’ve got a new full time maintainer? Big welcome to Ruben 😉 https://twitter.com/rubenfonseca
Changes
🌟New features and non-breaking changes
- feat(idempotency): handle lambda timeout scenarios for INPROGRESS records (#1387) by @rubenfonseca
📜 Documentation updates
- feat(idempotency): handle lambda timeout scenarios for INPROGRESS records (#1387) by @rubenfonseca
- docs(examples): enforce and fix all mypy errors (#1393) by @heitorlessa
🐛 Bug and hot fixes
- fix(event_handlers): ImportError when importing Response from top-level event_handler (#1388) by @VictorCovalski
🔧 Maintenance
- chore(deps): bump jsii from 1.57.0 to 1.63.1 (#1390) by @dependabot
- chore(deps): bump constructs from 10.1.1 to 10.1.59 (#1396) by @dependabot
- chore(deps-dev): bump flake8-isort from 4.1.1 to 4.1.2.post0 (#1384) by @dependabot
- docs(examples): enforce and fix all mypy errors (#1393) by @heitorlessa
- chore(ci): drop 3.6 from workflows (#1395) by @heitorlessa
- chore(maintainers): add Ruben as a maintainer (#1392) by @rubenfonseca
- chore(ci): add conditional to skip pypi release (#1366) by @heitorlessa
This release was made possible by the following contributors:
@VictorCovalski, @dependabot, @dependabot[bot], @heitorlessa, @rubenfonseca and Release bot