Closed obdevel closed 2 years ago
Solved.
The example given in TUTORIAL.md is incorrect. The correct usage is shown in V3/doc/EVENTS.md. e.g.
evt = await WaitAny((evp, evs)) # IS INCORRECT
evt = await WaitAny((evp, evs)).wait() # IS CORRECT
Apologies, you are right. Tutorial now fixed.
Trying to wait on multiple events, which are set by the two coroutines that are created. These coroutines work fine if created elsewhere, and I can wait on their events individually. I'm working from the example code in TUTORIAL.md.
Error output is:
Task exception wasn't retrieved future: coro= <generator object 'sequence_test_coro' at 2000a460>
Traceback (most recent call last):
File "uasyncio/core.py", line 1, in run_until_complete
File "module_asyncio.py", line 231, in sequence_test_coro
TypeError: 'WaitAny' object isn't iterable