-
-
Notifications
You must be signed in to change notification settings - Fork 4
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
Mypy typing? Getting that the methods are not available. Would like to have a clean mypy scan without ignores. #6
Comments
Sorry, I can't add new features in this library as this is just a patch layer on top of the official stripe library. I'll keep this issue open, but it won't be implemented until the official library gets typing support first. See related issue: stripe/stripe-python#650 |
You should at least be able to support the
or alternatively with
Until/if Stripe types their library, this will all resolve to |
In the meantime, for anyone stumbling on this who just wants a solution, it is safe to do, e.g.,
As long as you're not accidentally importing |
(after thinking about this for most of an hour it occurs to me that the monkeypatches actually will still keep this style of inference from working, because they are modifying a library at runtime that is inferred differently from that when it is imported statically. async-stripe would have to be redesigned without monkeypatches, sadly) |
Small update on this issue: stripe-python just got some basic typing support (PR stripe/stripe-python#1020). If it's possible, I will add typing support as well. |
Title.
Thank you for the great library
The text was updated successfully, but these errors were encountered: