Beispiel #1
0
 def callback(future):
     # print(("callback", future, future.result()))
     e = future.exception()
     if e:
         # print(("reject", e))
         promise.reject(e)
     else:
         promise.fulfill(future.result())
Beispiel #2
0
 def callback(future):
     # print(("callback", future, future.result()))
     e = future.exception()
     if e:
         # print(("reject", e))
         promise.reject(e)
     else:
         promise.fulfill(future.result())