Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
#!/usr/bin/env python
"""
This works fine in Python 3.3, but causes a strange error in Python 3.4.0:
TypeError: send() takes 2 positional arguments but 3 were given
"""
import asyncio
def t1(q):
yield from asyncio.sleep(0.5)
q.put_nowait((1, 2))
def t2(q):
v = yield from q.get()
print(v)
q = asyncio.Queue()
asyncio.get_event_loop().run_until_complete(asyncio.wait([t1(q), t2(q)]))
@richardkiss

This comment has been minimized.

Copy link
Owner Author

commented Apr 5, 2014

I can't reproduce this problem now. Argh!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.