Comments (3)
Hello @nymous ,
Sure go ahead with the PR, it will be a nice touch :)
Thanks
from httpx_auth.
Just to see how well it would work, I added the py.typed
file in the virtualenv of my application. When running mypy (in strict mode) I stumbled upon the following issue:
Module "httpx_auth" does not explicitly export attribute "OAuth2ClientCredentials"; implicit reexport disabled
This error also happens when using pyright with default configuration, and is because of this
This flag changes the behavior to not re-export unless the item is imported using from-as or is included in
__all__
.
(seen in this mypy docs).
To fix this would require to define in this __init__.py
a __all__
with everything you want to export, or to use the form from httpx_auth.aws import AWS4Auth as AWS4Auth
for every import.
Not doing this would require end users to add this configuration to mypy (I haven't look at how to do it with pyright):
[mypy-,httpx_auth.*]
no_implicit_reexport = False
How do you want to approach this? Do you prefer the code to stay untouched and document the configuration? Do you want to use the from ... import ... as ...
form?
Also, before adding the py.typed
file I wanted to check if mypy was happy with the code, and... mypy found 30 issues, pyright 26 😅 Would you be interested in a contribution to improve the internal types?
Should I start with the simple py.typed
+ PyPI classifier PR, then another for the types, with maybe a release after both?
from httpx_auth.
Every contribution is more than welcome :)
Indeed I would rather have PR as small as possible, I don't mind multiple PRs at all :)
So a first one with the py.typed and the classifier, then a second one with the all as in this PR on another project ?
And If you still feel like it, feel free to address the issues mypy and pyright found in another PR after that :D
Thanks again
from httpx_auth.
Related Issues (20)
- [BUG] Token renewal is not working HOT 3
- Allow for urn:ietf:wg:oauth:2.0:oob redirect_uri HOT 11
- Question: Why define headers to sign HOT 3
- There is a security vulnerability in httpx<0.23.0 HOT 1
- Basic auth should not be enforced for resource owner password flow HOT 7
- ENH: AWS4Auth - add option to use boto3 for automatically retrieving credentials HOT 8
- Document how to use botocore to retrieve AWS credentials
- Handle WakaTime auth HOT 2
- Feature request: Google Cloud Auth
- Okta client credentials should not request OpenID scope by default HOT 1
- Authentication for Java Server Pages or Spring Basic Login HOT 2
- Creating AWS4Auth instances with STS tokens leaks memory, slows down over time HOT 2
- AWS4Auth produces incomplete canonical query string HOT 4
- thoughts on async implementation HOT 7
- Raise more concrete exceptions
- Relax or update httpx dependency version. HOT 1
- implicit doesn't support scope
- httpx_auth above v0.20.0 Results in a 403 Forbidden error on AWS API Gateway `execute-api` service with AWS Signature Version 4 auth HOT 1
- JSONDecodeError due to Improper Handling of Nested JSON Strings in JWT Payloads
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from httpx_auth.