Skip to content

Conversation

@dependabot
Copy link
Contributor

@dependabot dependabot bot commented on behalf of github Oct 27, 2025

Bumps aws-lambda-powertools from 2.35.1 to 3.22.0.

Release notes

Sourced from aws-lambda-powertools's releases.

v3.22.0

Summary

This release enhances our Event Handler with support for Pydantic Models when validating query strings and headers parameters. This addition brings type safety, automatic validation, and better developer experience to your API endpoints.

A super thanks to @​tonnico for implementing this important feature 🚀 🌟

📜 Announcement: You can now find our documentation on the official AWS documentation domain at docs.aws.amazon.com/powertools/python.

Using Pydantic models to validate query strings and headers parameters

Docs

You can now use Pydantic's models to validate query strings and headers parameters. This allows you to have structured, type-safe validation with automatic error handling and clear validation messages.

Why this important:

  • Type safety: Catch validation errors at runtime with clear error messages
  • Developer experience: Get IDE autocompletion and type hints for your parameters
  • Documentation: Self-documenting code through Pydantic model definitions
  • Model reusability: Use the same validation model across multiple endpoints for consistency

Changes

🌟New features and non-breaking changes

  • feat(event_handler): add support for Pydantic models in Query and Header types (#7253) by @​tonnico

📜 Documentation updates

🐛 Bug and hot fixes

🔧 Maintenance

... (truncated)

Changelog

Sourced from aws-lambda-powertools's changelog.

[v3.22.0] - 2025-10-21

Bug Fixes

  • event_handler: Preserve examples field in OpenAPI schema for BedrockAgentResolver (#7561)

Documentation

  • idempotency: removed inexistent css class (#7539)

Features

  • event_handler: add support for Pydantic models in Query and Header types (#7253)

Maintenance

  • version bump
  • use approved sample names and addresses (#7542)
  • ci: new pre-release 3.21.1a5 (#7538)
  • ci: new pre-release 3.21.1a4 (#7528)
  • ci: new pre-release 3.21.1a7 (#7563)
  • ci: new pre-release 3.21.1a0 (#7500)
  • ci: update CONTRIBUTING.md (#7549)
  • ci: new pre-release 3.21.1a6 (#7548)
  • ci: new pre-release 3.21.1a1 (#7506)
  • ci: improve message when do-not-merge label is present (#7505)
  • ci: new pre-release 3.21.1a3 (#7519)
  • ci: new pre-release 3.21.1a2 (#7514)
  • deps: bump squidfunk/mkdocs-material from 00f9276 to f5c556a in /docs (#7530)
  • deps: bump mkdocs-material from 9.6.21 to 9.6.22 in /docs (#7531)
  • deps: bump pydantic from 2.12.0 to 2.12.2 (#7522)
  • deps: bump mkdocs-material from 9.6.21 to 9.6.22 (#7534)
  • deps: bump avro from 1.12.0 to 1.12.1 (#7546)
  • deps: bump protobuf from 6.32.1 to 6.33.0 (#7544)
  • deps: bump pydantic from 2.12.2 to 2.12.3 (#7556)
  • deps: bump actions/setup-node from 5.0.0 to 6.0.0 (#7521)
  • deps: bump valkey-glide from 2.1.0 to 2.1.1 (#7498)
  • deps: bump actions/dependency-review-action from 4.8.0 to 4.8.1 (#7516)
  • deps-dev: bump nox from 2024.10.9 to 2025.10.14 (#7532)
  • deps-dev: bump boto3-stubs from 1.40.49 to 1.40.51 (#7517)
  • deps-dev: bump cfn-lint from 1.40.1 to 1.40.2 (#7525)
  • deps-dev: bump aws-cdk-lib from 2.219.0 to 2.220.0 (#7524)
  • deps-dev: bump aws-cdk-aws-lambda-python-alpha from 2.219.0a0 to 2.220.0a0 (#7526)
  • deps-dev: bump cdklabs-generative-ai-cdk-constructs from 0.1.310 to 0.1.311 (#7523)
  • deps-dev: bump boto3-stubs from 1.40.47 to 1.40.49 (#7503)
  • deps-dev: bump ijson from 3.4.0 to 3.4.0.post0 (#7510)
  • deps-dev: bump aws-cdk from 2.1029.4 to 2.1030.0 (#7508)
  • deps-dev: bump cdklabs-generative-ai-cdk-constructs from 0.1.309 to 0.1.310 (#7509)
  • deps-dev: bump boto3-stubs from 1.40.51 to 1.40.53 (#7535)
  • deps-dev: bump sentry-sdk from 2.41.0 to 2.42.0 (#7533)
  • deps-dev: bump cfn-lint from 1.40.0 to 1.40.1 (#7502)

... (truncated)

Upgrade guide

Sourced from aws-lambda-powertools's upgrade guide.


title: Upgrade guide description: Guide to update between major Powertools for AWS Lambda (Python) versions

End of support v2

!!! warning "On March 25st, 2025, Powertools for AWS Lambda (Python) v2 reached end of support and will no longer receive updates or releases. If you are still using v2, we strongly recommend you to read our upgrade guide and update to the latest version."

Given our commitment to all of our customers using Powertools for AWS Lambda (Python), we will keep Pypi{target="_blank"} v2 releases and documentation 2.x versions to prevent any disruption.

Migrate to v3 from v2

!!! info "We strongly encourage you to migrate to v3. However, if you still need to upgrade from v1 to v2, you can find the upgrade guide."

We've made minimal breaking changes to make your transition to v3 as smooth as possible.

Quick summary

Area Change Code change required
Pydantic We have removed support for Pydantic v1 No
Parser We have replaced DynamoDBStreamModel AttributeValue with native Python types Yes
Parser We no longer export Pydantic objects from parser.pydantic. Yes
Lambda layer Lambda layers are now compiled according to the specific Python version and architecture No
Event Handler We have deprecated the get_header_value function. Yes
Batch Processor @batch_processor and @async_batch_processor decorators are now deprecated Yes
Event Source Data Classes We have updated default values for optional fields. Yes
Parameters The default cache TTL is now set to 5 minutes No
Parameters The config parameter is deprecated in favor of boto_config Yes
JMESPath Functions The extract_data_from_envelope function is deprecated in favor of query Yes
Types file We have removed the type imports from the shared/types.py file Yes

First Steps

Before you start, we suggest making a copy of your current working project or create a new branch with git.

  1. Upgrade Python to at least v3.9.
  2. Ensure you have the latest version via Lambda Layer or PyPi{target="_blank"}.
  3. Review the following sections to confirm if you need to make changes to your code.

Drop support for Pydantic v1

!!! note "No code changes required"

As of June 30, 2024, Pydantic v1 has reached its end-of-life, and we have discontinued support for this version. We now exclusively support Pydantic v2.

Use Pydantic v2 Migration Guide{target="_blank"} to migrate your custom Pydantic models to v2.

... (truncated)

Commits
  • 635892e chore: version bump
  • 7ebd820 fix(event_handler): Preserve examples field in OpenAPI schema for BedrockAg...
  • 7c4261e chore(ci): changelog rebuild (#7560)
  • ff994b5 chore(ci): new pre-release 3.21.1a7 (#7563)
  • 366d69c chore(deps-dev): bump sentry-sdk from 2.42.0 to 2.42.1 (#7562)
  • a498401 chore(ci): changelog rebuild (#7559)
  • a521a94 chore(ci): changelog rebuild (#7558)
  • 9978331 chore(deps-dev): bump nox from 2025.10.14 to 2025.10.16 (#7557)
  • 63ca4b2 chore(deps-dev): bump mypy-boto3-appconfigdata from 1.40.0 to 1.40.55 in the ...
  • 64bb665 chore(deps-dev): bump boto3-stubs from 1.40.54 to 1.40.55 (#7555)
  • Additional commits viewable in compare view

Dependabot compatibility score

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


Dependabot commands and options

You can trigger Dependabot actions by commenting on this PR:

  • @dependabot rebase will rebase this PR
  • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
  • @dependabot merge will merge this PR after your CI passes on it
  • @dependabot squash and merge will squash and merge this PR after your CI passes on it
  • @dependabot cancel merge will cancel a previously requested merge and block automerging
  • @dependabot reopen will reopen this PR if it is closed
  • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
  • @dependabot show <dependency name> ignore conditions will show all of the ignore conditions of the specified dependency
  • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)

@dependabot dependabot bot added dependencies Pull requests that update a dependency file python Pull requests that update Python code labels Oct 27, 2025
@dependabot dependabot bot requested a review from a team as a code owner October 27, 2025 01:09
@dependabot dependabot bot added dependencies Pull requests that update a dependency file python Pull requests that update Python code labels Oct 27, 2025
@github-actions
Copy link

💥 Something went wrong while deploying the pull request environment.
Check Output Logs

@dependabot dependabot bot force-pushed the dependabot/pip/aws-lambda-powertools-3.22.0 branch from 778dd83 to c1d0c90 Compare November 5, 2025 08:36
@github-actions
Copy link

github-actions bot commented Nov 5, 2025

💥 Something went wrong while deploying the pull request environment.
Check Output Logs

Bumps [aws-lambda-powertools](https://github.com/aws-powertools/powertools-lambda-python) from 2.35.1 to 3.22.0.
- [Release notes](https://github.com/aws-powertools/powertools-lambda-python/releases)
- [Changelog](https://github.com/aws-powertools/powertools-lambda-python/blob/develop/CHANGELOG.md)
- [Upgrade guide](https://github.com/aws-powertools/powertools-lambda-python/blob/develop/docs/upgrade.md)
- [Commits](aws-powertools/powertools-lambda-python@v2.35.1...v3.22.0)

---
updated-dependencies:
- dependency-name: aws-lambda-powertools
  dependency-version: 3.22.0
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
@dependabot dependabot bot force-pushed the dependabot/pip/aws-lambda-powertools-3.22.0 branch from c1d0c90 to 76415e4 Compare November 5, 2025 09:04
@sonarqubecloud
Copy link

sonarqubecloud bot commented Nov 5, 2025

@github-actions
Copy link

github-actions bot commented Nov 5, 2025

💥 Something went wrong while deploying the pull request environment.
Check Output Logs

@dependabot @github
Copy link
Contributor Author

dependabot bot commented on behalf of github Nov 10, 2025

Superseded by #1092.

@dependabot dependabot bot closed this Nov 10, 2025
@dependabot dependabot bot deleted the dependabot/pip/aws-lambda-powertools-3.22.0 branch November 10, 2025 01:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

dependencies Pull requests that update a dependency file python Pull requests that update Python code

Projects

None yet

Development

Successfully merging this pull request may close these issues.

0 participants