deps: Bump smol to 2.0 (#22956)
The collateral of this is that code size is increased by ~300kB, but I think we can stomach it. Release Notes: - N/A
This commit is contained in:
parent
1f84c1b6c7
commit
9e113bccd0
25 changed files with 187 additions and 330 deletions
|
@ -515,7 +515,7 @@ impl HeadlessProject {
|
|||
.query
|
||||
.ok_or_else(|| anyhow!("missing query field"))?,
|
||||
)?;
|
||||
let mut results = this.update(&mut cx, |this, cx| {
|
||||
let results = this.update(&mut cx, |this, cx| {
|
||||
this.buffer_store.update(cx, |buffer_store, cx| {
|
||||
buffer_store.find_search_candidates(&query, message.limit as _, this.fs.clone(), cx)
|
||||
})
|
||||
|
@ -527,7 +527,7 @@ impl HeadlessProject {
|
|||
|
||||
let buffer_store = this.read_with(&cx, |this, _| this.buffer_store.clone())?;
|
||||
|
||||
while let Some(buffer) = results.next().await {
|
||||
while let Ok(buffer) = results.recv().await {
|
||||
let buffer_id = buffer.update(&mut cx, |this, _| this.remote_id())?;
|
||||
response.buffer_ids.push(buffer_id.to_proto());
|
||||
buffer_store
|
||||
|
|
|
@ -187,7 +187,7 @@ async fn test_remote_project_search(cx: &mut TestAppContext, server_cx: &mut Tes
|
|||
cx.run_until_parked();
|
||||
|
||||
async fn do_search(project: &Model<Project>, mut cx: TestAppContext) -> Model<Buffer> {
|
||||
let mut receiver = project.update(&mut cx, |project, cx| {
|
||||
let receiver = project.update(&mut cx, |project, cx| {
|
||||
project.search(
|
||||
SearchQuery::text(
|
||||
"project",
|
||||
|
@ -203,7 +203,7 @@ async fn test_remote_project_search(cx: &mut TestAppContext, server_cx: &mut Tes
|
|||
)
|
||||
});
|
||||
|
||||
let first_response = receiver.next().await.unwrap();
|
||||
let first_response = receiver.recv().await.unwrap();
|
||||
let SearchResult::Buffer { buffer, .. } = first_response else {
|
||||
panic!("incorrect result");
|
||||
};
|
||||
|
@ -214,7 +214,7 @@ async fn test_remote_project_search(cx: &mut TestAppContext, server_cx: &mut Tes
|
|||
)
|
||||
});
|
||||
|
||||
assert!(receiver.next().await.is_none());
|
||||
assert!(receiver.recv().await.is_err());
|
||||
buffer
|
||||
}
|
||||
|
||||
|
|
|
@ -249,7 +249,7 @@ impl ServerListeners {
|
|||
|
||||
fn start_server(
|
||||
listeners: ServerListeners,
|
||||
mut log_rx: Receiver<Vec<u8>>,
|
||||
log_rx: Receiver<Vec<u8>>,
|
||||
cx: &mut AppContext,
|
||||
) -> Arc<ChannelClient> {
|
||||
// This is the server idle timeout. If no connection comes in in this timeout, the server will shut down.
|
||||
|
@ -351,8 +351,8 @@ fn start_server(
|
|||
}
|
||||
}
|
||||
|
||||
log_message = log_rx.next().fuse() => {
|
||||
if let Some(log_message) = log_message {
|
||||
log_message = log_rx.recv().fuse() => {
|
||||
if let Ok(log_message) = log_message {
|
||||
if let Err(error) = stderr_stream.write_all(&log_message).await {
|
||||
log::error!("failed to write log message to stderr: {:?}", error);
|
||||
break;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue