-
Notifications
You must be signed in to change notification settings - Fork 315
Closed
Milestone
Description
I get the below error,
future cannot be sent between threads safely
the trait `Send` is not implemented for `(dyn Stream<Item = Result<ListDocumentsResponse<workspace::WorkSpace>, azure_core::error::Error>> + 'static)`
required for the cast to the object type `dyn Future<Output = Vec<workspace::WorkSpace>> + Send`rustc
cosmos_service.rs(57, 20): future is not `Send` as this value is used across an await
cosmos_service.rs(53, 19): consider moving this into a `let` binding to create a shorter lived borrow
Code:
let respo = self .client .list_documents() .into_stream::<WorkSpace>() .next() .await .unwrap().unwrap().documents;
Could someone please help me?
Metadata
Metadata
Assignees
Labels
No labels