Closed karvetskiy closed 2 days ago
Thanks for opening your first issue here! We'll come back to you as soon as we can. In the meantime, check out the #python channel on our Powertools for AWS Lambda Discord: Invite link
Checking now.
Hi @karvetskiy, thanks for opening this issue and reporting this bug. Our tests didn't catch accessing current_event
using the Router
object directly and because of this we have this breaking change in this release, sorry about that. I'm working to fix and will release a new version in a few minutes.
Thanks
Hey @karvetskiy! If I publish a pre-release on Pypi, can you test if the issue is resolved in your environment before we release a new patch release? Thanks
Hey @leandrodamascena! Just checked alpha version, still can't access current_event
.
Looks like new Router
class in event_handler.graphql_appsync.router
inhered from wrong implementation of BaseRouter
class.
It has different implementation in v2.39.1 (see code)
he hasn't published yet, will ping you shortly @karvetskiy
PR incoming, we've been wrestling with static typing and additional tests to be quadruple sure this would work on areas we were missing tests too.
Once we merge and publish the alpha release we ping you
kicked off pre-release (should be in PyPi in ~6 minutes or so).. https://github.com/aws-powertools/powertools-lambda-python/actions/runs/9712027684
Hey @karvetskiy! alpha release is available. Can you test pls?
This is now released under 2.40.1 version!
Expected Behaviour
In out code we accessed
current_event
directly fromRouter
class befor 2.40.0Current Behaviour
In 2.40.0 version
current_event
available inAppSyncResolver
onlyCode snippet
Possible Solution
No response
Steps to Reproduce
call
current_event
attribute from Router classPowertools for AWS Lambda (Python) version
2.40.0
AWS Lambda function runtime
3.12
Packaging format used
Lambda Layers
Debugging logs
No response