New features
- You can configure more retry options for
ctx.run_typed:
ctx.run_typed("payment", payment, RunOptions(
# Initial retry interval
initial_retry_interval=timedelta(milliseconds=100),
# Retry policies are exponential, the retry interval will double on each attempt
retry_interval_factor=2.0,
# Maximum retry interval
max_retry_interval=timedelta(seconds=10),
# Max duration of retries before giving up
max_duration=timedelta(minutes=5),
# Max attempts (including the initial) before giving up
max_attempts=10,
))- You can now provide a name to
sleep, you'll be able to see this name in the UI.
Notable changes
- When suspending, the SDK will now throw an
asyncio.CancelledError, instead of the previously thrown custom error. Catch this exception only if you need to cleanup some external resources between execution attempts.
What's Changed
- Use task cancellation instead of custom suspension exception by @slinkydeveloper in #132
- Remove typing_extensions dependency by @slinkydeveloper in #133
- Copy RunOptions when mutating them by @slinkydeveloper in #135
- Add name parameter to sleep by @slinkydeveloper in #136
- Fix ctx.time() by @slinkydeveloper in #138
- Expose all run retry options by @slinkydeveloper in #137
- Test suite 3.2 upgrade by @slinkydeveloper in #139
- Use service image by @slinkydeveloper in #140
- Fix lint warning by @igalshilman in #141
Full Changelog: v0.10.1...v0.11.0