Message409821
I just found this PR when a task of mine spontaneously crashed with a "Task was destroyed but it is pending" in the middle of program execution.
I think the warning should be added to `loop.create_task()`, too. Not sure if `loop.call_later()` and `loop.call_at()` are also affected?
I think it would be a good idea to add the fire-and-forget example that @bernat gave. At the moment, stackoverflow is full of suggestions to just use `create_task()` in this case, ignoring the return value. Actually, I think it is a true shortcoming that asyncio doesn't provide a fire-and forget functionality by itself. |
|
Date |
User |
Action |
Args |
2022-01-06 08:53:46 | alexhartl | set | recipients:
+ alexhartl, docs@python, cmeyer, nanjekyejoannah, bernat |
2022-01-06 08:53:46 | alexhartl | set | messageid: <1641459226.61.0.108210360366.issue44665@roundup.psfhosted.org> |
2022-01-06 08:53:46 | alexhartl | link | issue44665 messages |
2022-01-06 08:53:46 | alexhartl | create | |
|