You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Bug: SecretsProvider.get_multiple appends to the caller's Filters list on every call #8596
Passing Filters=[...] through sdk_options leaves the caller's list untouched and sends only that filter plus the current name filter.
Current Behaviour
_get_multiple (secrets.py:157-160) does filters.append(name_filter) on the list object the caller passed. A module-level Filters constant, as in the docs example, grows one stale name filter per call, and the second request sends both.
filters = [*sdk_options.get("Filters", []), name_filter] instead of appending in place.
Steps to Reproduce
Run the snippet above (it uses botocore.stub.Stubber, no AWS access needed).
Powertools for AWS Lambda (Python) version
latest
AWS Lambda function runtime
3.13
Packaging format used
PyPi
Debugging logs
Warning
This issue is ready to be picked up, by humans or by agents. If you want it, comment here first so we can assign it to you, and please take only one or two issues at a time so others can join in too. The reproduction above runs locally without AWS access. Thanks!
Picked this up — reproduced the accumulation with the snippet from the report. The fix builds a new filters list instead of appending to the caller's, and adds a regression test for the reuse case.
Activity
leandrodamascena commentedon Oct 19, 2026
Hey @wanjinhao1 thanks, #8604 is yours. Will review.
macoladik commentedon Oct 22, 2026
Picked this up — reproduced the accumulation with the snippet from the report. The fix builds a new filters list instead of appending to the caller's, and adds a regression test for the reuse case.
PR: #8650