Пример #1
0
 def recurse() -> Do:
     result = yield thunk()
     done = check(result)
     yield (TmuxIO.pure(result) if done else TmuxIO.error(error)
            if time.time() - start > timeout else wait_and_recurse())
Пример #2
0
 def error(self, e: str) -> 'TmuxIOState[S, A]':
     return TmuxIOState.lift(TmuxIO.error(e))