-
Notifications
You must be signed in to change notification settings - Fork 2.6k
Add streamable_http_client
and deprecate old usage
#869
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
Conversation
- [Prompts](#prompts) | ||
- [Images](#images) | ||
- [Context](#context) | ||
- [Authentication](#authentication) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
My IDE added those... Which seems correct.
timeout: float | timedelta = 30, | ||
sse_read_timeout: float | timedelta = 60 * 5, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is backwards compatible.
timeout.total_seconds(), | ||
sse_read_timeout.total_seconds(), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We should use total_seconds()
, not seconds
. Only seconds
was wrong.
), # url, headers, timeout, sse_read_timeout, terminate_on_close | ||
], | ||
) | ||
async def test_establish_session_parameterized( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've added type hints, and simplified this test.
This test shouldn't exist as is, it's very confusing, and full of mocking, but I just adapted it for the sake of my changes.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Copilot encountered an error and was unable to review this pull request. You can try again by re-requesting a review.
The module is named
streamable_http_client
, it doesn't make sense for the function to be calledstreamablehttp_client
.