-
-
Notifications
You must be signed in to change notification settings - Fork 394
Closed
Description
Now that CancelScopes are becoming more exposed to users with #607 / #835, it occurred to me that it might be nice to have a weird magical .timeout property on them. The definition would be:
@property
def timeout(self):
return max(0.0, self._deadline - trio.current_time())
@timeout.setter
def timeout(self, new_timeout):
self.deadline = trio.current_time() + new_timeoutReactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels