recent_projects: Surface project opening errors to user (#41308)

Release Notes:

- N/A *or* Added/Fixed/Improved ...
This commit is contained in:
Lukas Wirth
2025-10-28 06:44:44 +00:00
committed by GitHub
parent 73bd12ebbe
commit 46c5d515bf
3 changed files with 77 additions and 75 deletions
+5 -5
View File
@@ -528,6 +528,7 @@ impl RemoteClient {
let reconnect_task = cx.spawn(async move |this, cx| {
macro_rules! failed {
($error:expr, $attempts:expr, $ssh_connection:expr, $delegate:expr) => {
delegate.set_status(Some(&format!("{error:#}", error = $error)), cx);
return State::ReconnectFailed {
error: anyhow!($error),
attempts: $attempts,
@@ -999,11 +1000,10 @@ impl ConnectionPool {
let connection = self.connections.get(&opts);
match connection {
Some(ConnectionPoolEntry::Connecting(task)) => {
let delegate = delegate.clone();
cx.spawn(async move |cx| {
delegate.set_status(Some("Waiting for existing connection attempt"), cx);
})
.detach();
delegate.set_status(
Some("Waiting for existing connection attempt"),
&mut cx.to_async(),
);
return task.clone();
}
Some(ConnectionPoolEntry::Connected(ssh)) => {