gradio/js/wasm/svelte
Yuichiro Tachibana (Tsuchiya) 5d00dd37ca
Make <UploadProgress /> Wasm-compatible (#6965)
* Make <UploadProgress /> Wasm-compatible

* add changeset

* Fix <DownloadLink /> not to prefetch the data in the Wasm mode

* add changeset

* Fix <DownloadLink /> to check the `window` object existence for SSR

* Lite: Fix and improve the file upload progress SSE (#6978)

* Update the Wasm ASGI connection to be able handle ReadableStream, which is used for example in <Upload />"

* Fix wasm_proxied_fetch() not to pass a leading '?' in the query_string to WorkerProxy.httpRequest() because it's required by the ASGI spec

* Fix FileUploadProgress.update() to merge a new item to the existing one in the queue

* Fix the SSE stream async task in the /upload_progress endpoint removing an unreached code block. `await asyncio.sleep()` has been moved from the unreached block to a live location, so the stream cadence has been reduced

* Fix `FileUploadProgress` to manage the `is_done` flag independent from the queue because it has a different semantics and checking it is a priority over reading other progress events to abort the SSE stream when uploading is done

* Refactoring

---------

Co-authored-by: gradio-pr-bot <gradio-pr-bot@users.noreply.github.com>
Co-authored-by: Ali Abdalla <ali.si3luwa@gmail.com>
2024-01-10 21:27:58 +04:00
..
context.ts Lite: Make the Examples component display media files using pseudo HTTP requests to the Wasm server (#5627) 2023-10-17 01:26:49 +09:00
DownloadLink.svelte Make <UploadProgress /> Wasm-compatible (#6965) 2024-01-10 21:27:58 +04:00
file-url.ts Make <UploadProgress /> Wasm-compatible (#6965) 2024-01-10 21:27:58 +04:00
index.ts Lite v4 (#6398) 2023-12-12 22:10:16 +00:00