File tree Expand file tree Collapse file tree 2 files changed +8
-1
lines changed Expand file tree Collapse file tree 2 files changed +8
-1
lines changed Original file line number Diff line number Diff line change @@ -5,6 +5,7 @@ edition = "2021"
55
66[dependencies ]
77gpui = { git = " https://github.com/zed-industries/zed" }
8+ gpui_tokio = { git = " https://github.com/zed-industries/zed" }
89http_client = { git = " https://github.com/zed-industries/zed" }
910reqwest_client = { git = " https://github.com/zed-industries/zed" }
1011anyhow = " 1"
Original file line number Diff line number Diff line change @@ -13,6 +13,8 @@ use mybinder::parse_binder_build_response;
1313use reqwest_client:: ReqwestClient ;
1414
1515fn app_main ( cx : & mut App ) {
16+ gpui_tokio:: init ( cx) ;
17+
1618 let http_client = Arc :: new (
1719 ReqwestClient :: proxy_and_user_agent ( None , "github.com/runtimed/smoke" )
1820 . expect ( "could not start HTTP client" ) ,
@@ -164,7 +166,11 @@ fn app_main(cx: &mut App) {
164166
165167 println ! ( "{}" , "🌽 Kernel launched" . bright_yellow( ) ) ;
166168
167- let ( ws, _ws_response) = remote_server. connect_to_kernel ( & kernel_id) . await ?;
169+ let ws = gpui_tokio:: Tokio :: spawn ( cx, async move {
170+ let ( ws, _ws_response) = remote_server. connect_to_kernel ( & kernel_id) . await ?;
171+ anyhow:: Ok ( ws)
172+ } ) ?
173+ . await ??;
168174
169175 let ( mut w, mut r) = ws. split ( ) ;
170176
You can’t perform that action at this time.
0 commit comments