-
Type: Task
-
Resolution: Done
-
Priority: Major - P3
-
Affects Version/s: None
-
Component/s: None
-
None
Python 3.5.2 will ship an update to the async iter protocol:
In CPython 3.5.2, the __aiter__ protocol was updated. Before 3.5.2, __aiter__ was expected to return an awaitable resolving to an asynchronous iterator . Starting with 3.5.2, __aiter__ should return asynchronous iterators directly. If the old protocol is used in 3.5.2, Python will raise a PendingDeprecationWarning . In CPython 3.6, the old __aiter__ protocol will still be supported with a DeprecationWarning being raised. In CPython 3.7, the old __aiter__ protocol will no longer be supported: a RuntimeError will be raised if __aiter__ returns anything but an asynchronous iterator.
MotorCursor probably needs updating. We may need conditional compilation for Python 3.5.0 and 3.5.1.
https://www.python.org/dev/peps/pep-0492/#api-design-and-implementation-revisions