Skip to content

Make generated Client and AuthenticatedClient take an httpx.Timeout object optionally? #745

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

Closed
mdlam92 opened this issue Apr 3, 2023 · 1 comment
Labels
✨ enhancement New feature or improvement
Milestone

Comments

@mdlam92
Copy link

mdlam92 commented Apr 3, 2023

I find myself making a wrapper for the Client object to implement taking an httpx.Timeout object.

It would be cool if the generated Client objects took an float as it does today but also accepted the httpx.Timeout type for the timeout keyword argument.

httpx's Timeout is nice because it lets you configure specific timeouts for read/write/connect/global.

I'm willing to make the PR, wanted to gauge interest or if the maintainer will consider this before I go and do it.

@mdlam92 mdlam92 added the ✨ enhancement New feature or improvement label Apr 3, 2023
@emann
Copy link
Collaborator

emann commented Apr 27, 2023

Should be a pretty simple change, just tweaking the type hints as far as I can tell. This may be better served waiting until #202 is implemented, however

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
✨ enhancement New feature or improvement
Projects
None yet
Development

No branches or pull requests

3 participants