RuntimeWarning: coroutine 'EventSourceResponse.send' was never awaited
d21d3q opened this issue · comments
Problem occurred yesterday in my project, I spent half day undoing commits to have it back working...
Now I tried to run simple.py
demo from this repo and I'm having the same problem.
Steps to reproduce
git clone <aiohttp_sse>
cd aiohttp_sse
virtualenv -p python3.6 venv
source venv/bin/activate
pip install aiohttp aiohttp_sse
python examples/simple/py
and after opening localhost:8080/index
browser shows only Response from server:
and console shows this output:
======== Running on http://127.0.0.1:8080 ========
(Press CTRL+C to quit)
foo
examples/simple.py:12: RuntimeWarning: coroutine 'EventSourceResponse.send' was never awaited
resp.send('foo {}'.format(i))
foo
foo
...
wireshark doesn't show any traffic after GET /hello
. only some TCP ACK.
is it possible that it crashes somewhere inside aiohttp
?
And here is origin of problem. aiohttp
changed api