Using wstd from another event loop on WASI 0.2, without block_on
Los mantenedores suelen responder en 5 días
Nadie ha tomado este issue todavía.
Evaluación
- Dificultad
- 5/5
- Tiempo estimado
- Más de una semana
- Aptitud para principiantes
- 30/100
- Tipo de issue
- Nueva funcionalidad
- Claridad
- Necesita aclaración
- Estado de actividad
- Activo
- Stack tecnológico
- rust, wasm
- Área
- backend, operating-systems
Línea de trabajo
Start by reproducing the panic when wstd futures are created or polled from GPUI tasks during the exported tick function, using the embedded_gpui and wasm32-wasip2 context described here. Read wstd's runtime and reactor integration alongside GPUI's executor; done would require an agreed, supported way to use http::Client, net::TcpListener, or timers without blocking block_on.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
We run GPUI (Zed's UI framework) inside a wasm32-wasip2 component, through embedded_gpui. The host drives the component by calling an exported tick function repeatedly. Each call runs GPUI's executor until it is idle and must return promptly: the plugin's UI has to keep responding, and the host enforces a time budget per call.
Plugin code, running as GPUI tasks, wants to await wstd's I/O: http::Client, net::TcpListener, timers.
Outside block_on this panics as soon as a wstd future is created or
polled:
Reactor::current must be called within a wstd runtime
block_on isn't usable here. It holds the thread until the future completes, so the UI freezes for the whole request, and the call can outlive the host's time budget. Long waits, such as an OAuth redirect listener waiting for the user to finish signing in in their browser, can't be done at all.
So there is no way to use wstd from a component whose thread belongs to another event loop. Is there a supported way to do this, or would you be open to adding one?
- Lenguaje dominante
- Rust
- Estrellas
- 136
- Forks
- 21
- Merge medio
- 5 d 6 h
- PR fusionados (30 d)
- 11
Preparar el entorno
- Sin Dockerfile ni archivo de Docker Compose
- Sin plantilla de pull request
- Leer la guía de contribución
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de bytecodealliance/wstd
-
Implement `http` on WASIp3Abierto
Dificultad 4/5 3-5 días Aptitud para principiantes 35/100
bytecodealliance/wstd#164 ·
Los mantenedores suelen responder en 5 días
-
Implement `net` on WASIp3Abierto
Dificultad 5/5 Más de una semana Aptitud para principiantes 25/100
bytecodealliance/wstd#161 ·
Los mantenedores suelen responder en 5 días
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 55/100
bytecodealliance/wstd#151 ·
Los mantenedores suelen responder en 5 días
-
Tracking issue for WASIp3Abierto
Dificultad 5/5 Más de una semana Aptitud para principiantes 32/100
bytecodealliance/wstd#141 · 6 comentarios · 1 reacción ·
Los mantenedores suelen responder en 5 días
-
Dificultad 4/5 3-5 días Aptitud para principiantes 45/100
bytecodealliance/wstd#109 ·
Los mantenedores suelen responder en 5 días
Todos los issues de bytecodealliance/wstd
Issues similares
-
Dificultad 1/5 Menos de una hora Aptitud para principiantes 80/100
Devolutions/picky-rs#546 · 1 comentario ·
Los mantenedores suelen responder en 3 días
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 74/100
Los mantenedores suelen responder en 1 día
-
enhancement
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
zcashlabs/thus-spoke-zakura#153 ·
Los mantenedores suelen responder en 1 día
-
claude_code: step fails on session-scoped (`@inline`) plugins with `Invalid scope "session"`Abierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 79/100
topgrade-rs/topgrade#2395 ·
Los mantenedores suelen responder en 1 día
-
app bug windows-os
Dificultad 2/5 1-3 horas Aptitud para principiantes 67/100
Los mantenedores suelen responder en 1 día