Uh oh!
There was an error while loading. Please reload this page.
Introduce Hypercorn as a test HTTP/2 server - #412
Conversation
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
pgjones
commented
Sep 29, 2019
I think it is at a good stage for feedback. |
sethmlarson
left a comment
There was a problem hiding this comment.
Thanks for opening this @pgjones! Here's some preliminary comments.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
| async with AsyncClient(backend=backend) as client: | ||
| response = await client.get("http://example.org") | ||
| @pytest.mark.skipif( |
There was a problem hiding this comment.
Can the h2_server raise the skip within the fixture?
lovelydinosaur
commented
Sep 30, 2019
From a POV of managing encode as a whole this one is a mixed bag. I'd personally much rather look at adding HTTP/2 support to uvicorn, than switch to hypercorn as the test server. It's also problematic for us to switch to something that has a different set of Python requirements, (3.7+) rather than being able to keep roughly in line across a suite of projects. I'm way more invested in promoting ecosystem-as-a-whole rather than individual projects, but just wrt. logisitics and management overhead, this change probably comes out as a net negative to me. |
pgjones
commented
Sep 30, 2019
Hi @tomchristie this adds Hypercorn as a test server rather than replacing uvicorn as the test server, as per #290. In its current form it only uses Hypercorn for the HTTP/2 tests. |
florimondmanca
left a comment
There was a problem hiding this comment.
I think this is a great addition.
There's definitely some refactoring required to help make the hypercorn-based HTTP/2 server as self-contained and isolated as possible. For example, move it to conftest.py with a custom H2Server class that exposes the required interface to be able to pass it to serve_in_thread(). I may draft a PR against your fork to demonstrate the idea. :)
pgjones
commented
Oct 4, 2019
@florimondmanca thanks. I'm happy to tidy this up - I just got it into a workable state to get initial thoughts. |
This allows the HTTP/2 tests to be directed at an actual HTTP/2 server rather than a mock server. This is beneficial as it is closer to the actual usage by users.
pgjones
commented
Oct 12, 2019
Thanks @florimondmanca I've pulled in your changes and rebased against master. |
Uh oh!
There was an error while loading. Please reload this page.
florimondmanca
commented
Nov 16, 2019
While I appreciate a lot the effort put into getting something (almost!) working for this one, this PR has gone a bit stale because opinions are mixed about eventually integrating it into master. I'll close it, and maybe we can take inspiration from this for a future implementation (maybe when Uvicorn gets HTTP/2?). Thanks @pgjones! ❤️ |
Bumps [furo](https://github.com/pradyunsg/furo) from 2021.8.31 to 2021.10.9. - [Release notes](https://github.com/pradyunsg/furo/releases) - [Changelog](https://github.com/pradyunsg/furo/blob/main/docs/changelog.md) - [Commits](pradyunsg/furo@2021.08.31...2021.10.09) --- updated-dependencies: - dependency-name: furo dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
This allows the HTTP/2 tests to be directed at an actual HTTP/2 server
rather than a mock server. This is beneficial as it is closer to the
actual usage by users.