1515//! ```
1616
1717use async_std:: task;
18- use futures :: FutureExt ;
18+ use futures_util :: future :: FutureExt ;
1919use pyo3:: prelude:: * ;
2020use std:: { any:: Any , cell:: RefCell , future:: Future , panic, panic:: AssertUnwindSafe , pin:: Pin } ;
2121
@@ -481,8 +481,8 @@ where
481481///
482482/// This function converts the `awaitable` into a Python Task using `run_coroutine_threadsafe`. A
483483/// completion handler sends the result of this Task through a
484- /// `futures::channel ::oneshot::Sender<PyResult<Py<PyAny>>>` and the future returned by this function
485- /// simply awaits the result through the `futures::channel ::oneshot::Receiver<PyResult<Py<PyAny>>>`.
484+ /// `futures_channel ::oneshot::Sender<PyResult<Py<PyAny>>>` and the future returned by this function
485+ /// simply awaits the result through the `futures_channel ::oneshot::Receiver<PyResult<Py<PyAny>>>`.
486486///
487487/// # Arguments
488488/// * `awaitable` - The Python `awaitable` to be converted
@@ -544,7 +544,7 @@ pub fn into_future(
544544/// # Examples
545545/// ```
546546/// use pyo3::prelude::*;
547- /// use futures ::{StreamExt, TryStreamExt};
547+ /// use futures_util::stream ::{StreamExt, TryStreamExt};
548548/// use std::ffi::CString;
549549///
550550/// const TEST_MOD: &str = r#"
@@ -585,7 +585,7 @@ pub fn into_future(
585585#[ cfg( feature = "unstable-streams" ) ]
586586pub fn into_stream_v1 (
587587 gen : Bound < ' _ , PyAny > ,
588- ) -> PyResult < impl futures :: Stream < Item = PyResult < Py < PyAny > > > + ' static > {
588+ ) -> PyResult < impl futures_util :: stream :: Stream < Item = PyResult < Py < PyAny > > > + ' static > {
589589 generic:: into_stream_v1 :: < AsyncStdRuntime > ( gen)
590590}
591591
@@ -602,7 +602,7 @@ pub fn into_stream_v1(
602602/// # Examples
603603/// ```
604604/// use pyo3::prelude::*;
605- /// use futures ::{StreamExt, TryStreamExt};
605+ /// use futures_util::stream ::{StreamExt, TryStreamExt};
606606/// use std::ffi::CString;
607607///
608608/// const TEST_MOD: &str = r#"
@@ -647,7 +647,7 @@ pub fn into_stream_v1(
647647pub fn into_stream_with_locals_v1 (
648648 locals : TaskLocals ,
649649 gen : Bound < ' _ , PyAny > ,
650- ) -> PyResult < impl futures :: Stream < Item = PyResult < Py < PyAny > > > + ' static > {
650+ ) -> PyResult < impl futures_util :: stream :: Stream < Item = PyResult < Py < PyAny > > > + ' static > {
651651 generic:: into_stream_with_locals_v1 :: < AsyncStdRuntime > ( locals, gen)
652652}
653653
@@ -664,7 +664,7 @@ pub fn into_stream_with_locals_v1(
664664/// # Examples
665665/// ```
666666/// use pyo3::prelude::*;
667- /// use futures ::{StreamExt, TryStreamExt};
667+ /// use futures_util::stream ::{StreamExt, TryStreamExt};
668668/// use std::ffi::CString;
669669///
670670/// const TEST_MOD: &str = r#"
@@ -709,7 +709,7 @@ pub fn into_stream_with_locals_v1(
709709pub fn into_stream_with_locals_v2 (
710710 locals : TaskLocals ,
711711 gen : Bound < ' _ , PyAny > ,
712- ) -> PyResult < impl futures :: Stream < Item = Py < PyAny > > + ' static > {
712+ ) -> PyResult < impl futures_util :: stream :: Stream < Item = Py < PyAny > > + ' static > {
713713 generic:: into_stream_with_locals_v2 :: < AsyncStdRuntime > ( locals, gen)
714714}
715715
@@ -725,7 +725,7 @@ pub fn into_stream_with_locals_v2(
725725/// # Examples
726726/// ```
727727/// use pyo3::prelude::*;
728- /// use futures ::{StreamExt, TryStreamExt};
728+ /// use futures_util::stream ::{StreamExt, TryStreamExt};
729729/// use std::ffi::CString;
730730///
731731/// const TEST_MOD: &str = r#"
@@ -766,6 +766,6 @@ pub fn into_stream_with_locals_v2(
766766#[ cfg( feature = "unstable-streams" ) ]
767767pub fn into_stream_v2 (
768768 gen : Bound < ' _ , PyAny > ,
769- ) -> PyResult < impl futures :: Stream < Item = Py < PyAny > > + ' static > {
769+ ) -> PyResult < impl futures_util :: stream :: Stream < Item = Py < PyAny > > + ' static > {
770770 generic:: into_stream_v2 :: < AsyncStdRuntime > ( gen)
771771}
0 commit comments