Live data from Hacker News

Show HN: Asynchronous HTTP/2 client for Python 2.7

github.com

1–10 of 62 posts

Re: Show HN: Asynchronous HTTP/2 client for Python 2.7

#4
post #2

Its name made me think of THC. I'll ask the obvious question: why not Python 3?

Well, Python 3 already has a similar library that deals with this stuff, such as https://github.com/decentfox/aioh2.

Also, this is mostly intended for Tornado backends, offering compatibility with Tornado's request / response objects.

Re: Show HN: Asynchronous HTTP/2 client for Python 2.7

#6
Why Python 2 and not Python 3?

Short answer is: because Python 3 already benefits from a better, more complete client: aioh2 (https://github.com/decentfox/aioh2) that works with Python's asyncio.

th2c is mostly intended for Tornado backends, trying to keep a similar interface and compatibility with Request / Response objects.

It was initially developed in order to be able to communicate with APNS from a python 2.7 environment.

Re: Show HN: Asynchronous HTTP/2 client for Python 2.7

#7
post #4
post #2

Its name made me think of THC. I'll ask the obvious question: why not Python 3?

Well, Python 3 already has a similar library that deals with this stuff, such as https://github.com/decentfox/aioh2 . Also, this is mostly intended for Tornado backends, offering compatibility with Tornado's request / response objects.

I see. May I suggest linking to that in the README? And if you aren't part of the Python 2 forever camp, suggest how one might migrate from using your library to using python 3 with the other library in the future? And if the APIs aren't similar it might be a good idea to make them similar.

Re: Show HN: Asynchronous HTTP/2 client for Python 2.7

#8
post #5
post #3

Any specific reason to develop this for Python 2 rather than Python 3?

The end of life is in 2020 but it doesn’t say when. Is this still the latest? http://legacy.python.org/dev/peps/pep-0373/

It's January 1st, 2020.

https://mail.python.org/pipermail/python-dev/2018-March/1523...

Re: Show HN: Asynchronous HTTP/2 client for Python 2.7

#9
post #7
post #4

Earlier quoted context omitted.

Well, Python 3 already has a similar library that deals with this stuff, such as https://github.com/decentfox/aioh2 . Also, this is mostly intended for Tornado backends, offering compatibility with Tornado's request / response objects.

I see. May I suggest linking to that in the README? And if you aren't part of the Python 2 forever camp, suggest how one might migrate from using your library to using python 3 with the other library in the future? And if the APIs aren't similar it might be a good idea to make them similar.

I understand your point, and I'll try to update the README with that information. However, this client tries to follow Tornado's ways, whereas aioh2 works on Python's asyncio.

It's still WIP, so feedback like yours helps a lot, thanks!

Re: Show HN: Asynchronous HTTP/2 client for Python 2.7

#10
post #6

Why Python 2 and not Python 3? Short answer is: because Python 3 already benefits from a better, more complete client: aioh2 ( https://github.com/decentfox/aioh2 ) that works with Python's asyncio. th2c is mostly intended for Tornado backends, trying to keep a similar interface and compatibility with Request / Response objects. It was initially developed in order to be able to communicate with APNS from a python 2.7…

How does that compare to aiohttp? What are the benefits?
Post reply on HN