https://github.com/aio-libs The set of asyncio-based libraries built with high quality
popravich on travis_pypy
.travis.yml: chaching pip packa… Makefile: build/install only re… .travis.yml: cache redis-server… (compare)
ClientSession.request()
allows me to specify an SSL Context, but aiohttp.request()
does not? Conversely - aiohttp.request()
lets me specify a connector, but ClientSession.request()
does not - the connector is specified upon session creation. I want to issue a number of requests via different proxies, providing my own SSLContext. Is there a better way of doing that aside from the only solution I'm currently seeing, i.e. creating new ClientSessions with preconfigured connectors for every proxy?
Hello!
When I'm creating a server for websockets, I've done this in my view:
current_websocket = web.WebSocketResponse(
autoping=True, heartbeat=10
)
How ever, if the client disconnects without sending a close-code, the client don't ever seem to disconnect. Every time I then try to send a message to that client I get this warning:
INFO:aiohttp_chat.utils:> Sending message {'action': 'chat_message', 'message': '', 'user': 'jonas'} to user123
WARNING:asyncio:socket.send() raised exception.
(user123 is no longer connected)
I've checked these things on the websocket connection:
websocket.closed() # False
websocket.status # 101
websocket.exception() # None
How can I see if a connection has been broken abruptive, when heartbeat
don't seem to inform me in any way?
try: finally
around the entire async for message in current_websocket:
is the way to do it. :)
Hello, thanks for maintaining this great library
I'm experiencing a weird bug - after fulfilling 100 parallel requests, both aiohttp and httpx just halt - no further requests can be made.
I'm probably doing something stupid, can someone please tell me what's the right way to do this?
RuntimeError: Session is closed
Hi, I was making a custom MultiPart form-data request and got a 502 (it's either nginx or Apache, so standard).
Commenting out this line was what made the request successful:
https://github.com/aio-libs/aiohttp/blob/5f0a59fd38f048ee65b6199a26d2355075d0d196/aiohttp/helpers.py#L372
Is this covered by some standard?
helpers.content_disposition_header
whether to encode the field value or not. In my case, it was an ASCII string. Also, curl
didn't encode it.