-
Notifications
You must be signed in to change notification settings - Fork 421
Static typing: logger.append_keys
produces a [no-untyped-call]
mypy error
#3112
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
Thanks for opening your first issue here! We'll come back to you as soon as we can. |
Hey @FollowTheProcess please feel free to send a PR 🥹 Thank you for taking the time to fill in such a great static typing issue -- we will definitely use this as a great example to follow ;) We're at events this week hence small delays in our usual response/triaging. Thank you!! |
Great! Done a first pass in #3113, surfaced a few questions though 🙂 |
|
This is now released under 2.25.1 version! |
Static type checker used
mypy (project's standard)
AWS Lambda function runtime
3.10
Powertools for AWS Lambda (Python) version
latest
Static type checker info
Output
Config
Run
I just run
mypy
on the command line from within the virtual environmentCode snippet
Possible Solution
It seems that in a few places in powertools where a function or method would return
None
, the return type annotation is omitted. One such example isappend_keys
powertools-lambda-python/aws_lambda_powertools/logging/logger.py
Line 596 in 812b63d
The solution would be to simply add
-> None:
as the return type annotation 🙂, preferably in other places where it's missing too.Happy to do a PR for this, just waiting for triage 👍🏻
The text was updated successfully, but these errors were encountered: