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: get_app_config ignores environment and application after the first call #8588
get_app_config(name, environment=..., application=...) reads from the environment and application passed on every call.
Current Behaviour
The module-level provider is created once under the key "appconfig" in DEFAULT_PROVIDERS (appconfig.py:218) with the first environment/application. Every later call reuses it, so a function that reads two applications or two environments silently gets the first one. The second call below even hits the cache for the wrong app.
Key the default provider by ("appconfig", environment, application) in DEFAULT_PROVIDERS, or recreate it when they differ. clear_caches() must still clear all of them.
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!
@leandrodamascena Hey, I’d like to work on this issue. I’ll look into the caching problem and try to fix it so different applications and environments use the correct configuration.
This issue is now closed. Please be mindful that future comments are hard for our team to see.
If you need more assistance, please either reopen the issue, or open a new issue referencing this one.
If you wish to keep having a conversation with other community members under this issue feel free to do so.
Activity
codewithzubair07 commentedon Oct 18, 2026
@leandrodamascena Hey, I’d like to work on this issue. I’ll look into the caching problem and try to fix it so different applications and environments use the correct configuration.
leandrodamascena commentedon Oct 18, 2026
Hey @codewithzubair07 yeah pls go ahead.
powertools-for-aws-oss-automation commentedon Oct 22, 2026
Warning
This issue is now closed. Please be mindful that future comments are hard for our team to see.
If you need more assistance, please either reopen the issue, or open a new issue referencing this one.
If you wish to keep having a conversation with other community members under this issue feel free to do so.