syrusakbary / promise

Ultra-performant Promise implementation in Python
MIT License
362 stars 76 forks source link

Allow duck typing for is_future check #1

Closed Globegitter closed 8 years ago

Globegitter commented 8 years ago

We are using a Future that is not neither a ConcurrentFuture or an AsyncIOFuture, but a GRPC future (https://github.com/grpc/grpc/blob/d0fbba52d6e379b76a69016bc264b96a2318315f/src/python/grpcio/grpc/framework/foundation/future.py#L63). This allows for any Future that implements add_done_callback to be used and resolves our issue.

coveralls commented 8 years ago

Coverage Status

Coverage increased (+0.6%) to 94.805% when pulling 04690be86b353700bbe9687de25cfa611b2c476b on Globegitter:patch-1 into 127a202f553f073e5c891231c8227c6800d4c210 on syrusakbary:master.