Open lordmauve opened 2 years ago
When writing Axium it became apparent that service tasks would be extremely helpful.
This is the same idea mentioned in the Trio tracker: https://github.com/python-trio/trio/issues/1521
For Axium these tasks might often be effects that update only as long as the nursery is alive:
async with w2d.Nursery() as ns: ns.do(drive_ship(ship)) ns.run_service(effects.trail(ship))
So if drive_ship() exits the trail is automatically cancelled.
drive_ship()
When writing Axium it became apparent that service tasks would be extremely helpful.
This is the same idea mentioned in the Trio tracker: https://github.com/python-trio/trio/issues/1521
For Axium these tasks might often be effects that update only as long as the nursery is alive:
So if
drive_ship()
exits the trail is automatically cancelled.