github whitphx/stlite @stlite/cloudflare@0.4.0

latest release: @stlite/react@1.8.1
2 hours ago

Minor Changes

  • #2115 5e87ca9 Thanks @whitphx! - Bundle the Python runtime into the Worker script by default. Cloudflare now caps a script at 64 MiB uncompressed on every plan instead of 3 MiB (Free) or 10 MiB (Paid) after gzip, and the packaged runtime fits that with room to spare, so a cold start no longer fetches and unpacks the runtime from static assets before the first import streamlit.

    The previous layout is still available as --asset-runtime, which keeps the packed libraries compressed in the isolate and is worth the extra cold-start work for an app running close to the 128 MB isolate limit.

  • #2123 f7af537 Thanks @whitphx! - Remove the --bundled-runtime flag. Bundling the Python runtime into the Worker script is the default, so the flag selected the behaviour you already get; --asset-runtime is the flag that changes it. Builds still passing --bundled-runtime now fail with an unknown-argument error instead of being silently ignored, and the fix is to drop it from the command.

Patch Changes

  • #2124 e805cae Thanks @whitphx! - Wait for parquet-wasm to finish instantiating before parsing a dataframe.

    Stlite parses Arrow payloads through parquet-wasm, whose reader throws until its WebAssembly module is instantiated. The initializer was started but never awaited, so an app that rendered a dataframe or an Arrow-backed chart before the 5.5 MB module finished loading took the page down with Cannot read properties of undefined (reading '__wbindgen_add_to_stack_pointer'). Bundling the Python runtime into the Cloudflare Worker script made that the common case rather than a rare one, because the app now boots without waiting on a runtime download first.

What's Changed

🏕 Updates

  • ci: replace Dependabot with Renovate by @whitphx in #2120
  • feat(cloudflare): bundle the Python runtime into the Worker script by default by @whitphx in #2115
  • feat(cloudflare): remove the --bundled-runtime flag by @whitphx in #2123
  • fix(deps): wait for parquet-wasm before parsing a dataframe by @whitphx in #2124
  • Version Packages by @whitphx-changesets-bot[bot] in #2122

Full Changelog: https://github.com/whitphx/stlite/compare/@stlite/react@1.8.0...@stlite/cloudflare@0.4.0

Don't miss a new stlite release

NewReleases is sending notifications on new releases.