Skip to content

Releases: aws-powertools/powertools-lambda-python

0.11.0

10 Jun 14:05
Compare
Choose a tag to compare

Changes

Fix a bug with Metrics causing an exception to be thrown when logging metrics if dimensions were not explicitly added. No longer throw exception when no metrics are emitted while using the log_metrics decorator. Top level module imports now available for core utils, eg: from aws_lambda_powertools import Logger, Metrics, Tracer.

This is the last planned release before this library becomes GA.

🌟 Minor Changes

  • fix: metrics default dimension creation (#74) by @cakepietoast
  • chore(deps): bump graphql-playground-html from 1.6.19 to 1.6.25 in /docs (#72) by @dependabot
  • feat: improve error handling for log_metrics decorator (#71) by @cakepietoast
  • feat: add high level imports (#70) by @heitorlessa

📜 Documentation updates

This release was made possible by the following contributors:

@cakepietoast and @heitorlessa

0.10.1

10 Jun 12:17
Compare
Choose a tag to compare

Changes

Fix a bug with Metrics causing an exception to be thrown when logging metrics if dimensions were not explicitly added.

🌟 Minor Changes

  • fix: metrics default dimension creation (#74) by @cakepietoast

This release was made possible by the following contributors:

@cakepietoast

0.10.0

08 Jun 11:32
967d86e
Compare
Choose a tag to compare

Changes

This release primarily consists of changes to the Metrics core utility. Most notably:

  • The Metrics constructor now accepts a service parameter (alternatively the POWERTOOLS_SERVICE_NAME env var), as with the Tracer and Logger interfaces. This will create a default dimension named "service", with the value provided. Note that if you're already using the env var, this new dimension will start being recorded after upgrading to this version.
  • You can now specify the namespace by passing a namespace parameter to the Metrics constructor, or by supplying the POWERTOOLS_METRICS_NAMESPACE env var. This should be preferred to using the add_namespace method, which has been deprecated and will be removed in a future release.
  • To avoid repetition for the common task of recording metrics for Lambda cold starts, you can now achieve this by passing the capture_cold_start_metric parameter to the log_metrics decorator.

🌟New features and non-breaking changes

  • feat: add capture_cold_start_metric for log_metrics (#67) by @heitorlessa
  • improv: update metrics interface to resemble other core utils (#60) by @cakepietoast
  • improv: Better namespace/dimension handling for Metrics (#62) by @cakepietoast

🌟 Minor Changes

This release was made possible by the following contributors:

@cakepietoast, @danilohgds, @heitorlessa, @jfuss and @nmoutschen