RFC for introducing Typing Extensions? #1307
Replies: 6 comments 11 replies
-
hey @peterschutt ! Absolutely, answers inline:
Yes, we should be bringing Typing Extensions.
Yes. What I'd like to see in the RFC is (1) Typing Extensions as a dev dependency vs runtime (bloat) and (2) What key features we should be using (e.g., TypedDict, ParamSpec, etc.)
Yes.
No rush at all :) We're also tied with operational excellence tasks that might take another month or so to complete Thanks a lot for the help, truly!! |
Beta Was this translation helpful? Give feedback.
-
Awesome. I'm looking forward to it. For now, I'll focus on getting a repo setup with an environment for examples, testing, docs etc, and I'll touch base again soon after I've had some time to think about those top-level issues you've mentioned you'd like to see addressed. |
Beta Was this translation helpful? Give feedback.
-
Fantastic. Feel free to ping at any time
…On Tue, 19 Jul 2022 at 11:02, Peter Schutt ***@***.***> wrote:
Awesome. I'm looking forward to it.
For now, I'll focus on getting a repo setup with an environment for
examples, testing, docs etc, and I'll touch base again soon after I've had
some time to think about those top-level issues you've mentioned you'd like
to see addressed.
—
Reply to this email directly, view it on GitHub
<#1307 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAZPQBAULCSJLYRCIJPN5QLVUZVLDANCNFSM53ZIQRXQ>
.
You are receiving this because you were mentioned.Message ID:
<awslabs/aws-lambda-powertools-python/repo-discussions/1307/comments/3178806
@github.com>
|
Beta Was this translation helpful? Give feedback.
-
Hey @heitorlessa - just touching base to let you know that I'm still keen to progress this - just happens that my schedule has filled to the brim so I'm battling for time - hopefully somewhat temporarily. If waiting on me is blocking anything feel free to progress without me. Otherwise, has anything changed or progressed on the library front relevant to this? Hope all is well for you and the team! Cheers. |
Beta Was this translation helpful? Give feedback.
-
Nice! I've used narrowing literals in overloads somewhere along the line before, but the default value stuff is new to me, TIL! From earlier branch of this discussion:
I've been running both mypy and pyright on my most recent project and we've been doing it in starlite for a little while via pre-commit. I've not noticed a lot of friction (although I think the starlite code base needs an audit of ignores), but I did come across one interesting difference in interpretation of class variable declarations that led me to an interesting read: ClassVar in protocols: mypy and pyright have different opinions I've had a good opportunity recently to add types to a code-base from scratch: tobymao/saq#43 - I used MonkeyType for the initial types which was quite effective! |
Beta Was this translation helpful? Give feedback.
-
That’s super interesting! In your experience, are you finding PyRight a
better fit for modern Python?
…On Tue, 25 Oct 2022 at 01:16, Peter Schutt ***@***.***> wrote:
Learned a new trick when trying to do overload for parameters too:
https://gist.github.com/heitorlessa/0ff113664e8192fd839dc8c7acfab812
Nice! I've used narrowing literals in overloads somewhere along the line
before, but the default value stuff is new to me, TIL!
From earlier branch of this discussion:
I'd keep mypy --strict in mind instead. PyRight
<https://github.com/microsoft/pyright> is improving fast, but I'm not
sure I'd use it as a standard.
I've been running both mypy and pyright on my most recent project (
https://github.com/topsport-com-au/starlite-saqlalchemy/blob/main/.github/workflows/ci.yml#L30)
and we've been doing it in starlite for a little while via pre-commit (
https://github.com/starlite-api/starlite/blob/5656144765ff9fe819b096937186fc2bc13e7c85/.pre-commit-config.yaml#L204).
I've not noticed a lot of friction (although I think the starlite code base
needs an audit of ignores), but I did come across one interesting
difference in interpretation of class variable declarations that led me to
an interesting read: ClassVar in protocols: mypy and pyright have
different opinions <python/typing#1056>
I've had a good opportunity recently to add types to a code-base from
scratch: tobymao/saq#43 <tobymao/saq#43> - I used
MonkeyType for the initial types which was quite effective!
—
Reply to this email directly, view it on GitHub
<#1307 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAZPQBGI64CDXBN7OYMCXF3WE4KGFANCNFSM53ZIQRXQ>
.
You are receiving this because you were mentioned.Message ID:
<awslabs/aws-lambda-powertools-python/repo-discussions/1307/comments/3955439
@github.com>
|
Beta Was this translation helpful? Give feedback.
-
Hey @heitorlessa and co.
I noticed this in release notes for
1.25.7
:... and as we spoke about a little while ago I have a some interest in this sort of stuff and think it would be a good vehicle to use for my own learning.
So I have a few questions:
Beta Was this translation helpful? Give feedback.
All reactions