Compatibility
GPUI-RSX’s primary verified target is GPUI Kit and its exact gpui-pre snapshot (published by Longbridge with independent version numbers from the official gpui crate).
The macro and core crates have no GPUI runtime dependency. Aliasing gpui-kit as gpui keeps generated gpui:: paths and GPUI derives aligned automatically.
Verified Compatibility
Section titled “Verified Compatibility”| GPUI-RSX | GPUI Kit | GPUI snapshot | Component |
|---|---|---|---|
0.13.0 |
0.10.0 |
gpui-pre@0.3.12 |
gpui-component@0.10.0 |
This matrix comes from demo/Cargo.lock. Kit supplies GPUI, components and assets; the Cargo alias below preserves the gpui:: path used by RSX expansions. Commit the application lockfile.
[dependencies]gpui = { package = "gpui-kit", version = "=0.10.0" }gpui-rsx = "0.13.0"Verification Scope
Section titled “Verification Scope”| Target | How it is validated | Coverage |
|---|---|---|
| Pinned Kit snapshot (above) | Generated API contract, demo builds, tests, and doctests on Linux & macOS CI | Full mapped GPUI method surface and documented Kit integration |
| Renamed Kit dependency | Dedicated demo CI fixture without a gpui crate alias |
Configured gpui-path, components, IDs, fragments, inline dynamic classes, and shared runtimes |
Official gpui = "=0.2.2" |
Dedicated macOS fixture sharing core regression cases | Keys, component defaults, fragments, events, identity, and state updates (not the full API surface) |
| Other versions or backends | Not covered by this matrix | Validate your dependency graph, generated code, and runtime behavior before adopting |
When diagnosing an unverified combination, establish a working baseline with the pinned matrix first, then change one dependency at a time.
Existing dependency aliases
Section titled “Existing dependency aliases”Prefer gpui = { package = "gpui-kit", ... }. If your crate already names the dependency something else (for example, engine), you have two options:
Option A: Crate-root alias
Section titled “Option A: Crate-root alias”[dependencies]engine = { package = "gpui-kit", version = "=0.10.0" }extern crate engine as gpui;With the default configuration, every binary, example, or integration-test target that uses RSX needs that alias in its own crate root.
Option B: Configure gpui-path in rsx.toml
Section titled “Option B: Configure gpui-path in rsx.toml”[options]gpui-path = "::engine"- Covers generated paths in markup, components, automatic IDs, dynamic keys,
rsx_listener!,rsx_update!, andrsx_runtime!(). - Supports crate-root re-exports such as
crate::ui(each target must expose that re-export). - Paths cannot contain generic arguments or start with
selforsuper. - An explicit
rsx_runtime!(::other_engine)overrides this setting. - With a custom
gpui-path,#[component]functions implementIntoElementviaViewElement, so GPUI 0.2.x (which usesComponent) supports#[component]functions only under the defaultgpuicrate name.
User expressions, explicit prop types, and GPUI’s own derive macros still follow their own imports (for instance, #[derive(engine::IntoElement)] may still reference gpui::). Verify the renamed-dependency fixture locally with:
cargo +1.98.1 test --manifest-path tests/fixtures/gpui-renamed/Cargo.toml --target-dir demo/targetCurrent Demo Matrix
Section titled “Current Demo Matrix”| Item | Value |
|---|---|
| Rendering backend | Kit’s default gpui-pre from crates.io |
| GPUI-RSX root crate MSRV | 1.88.0 |
| Demo Rust toolchain | 1.98.1 |
| Demo check command | cargo +1.98.1 check --manifest-path demo/Cargo.toml --bins --locked |
The root crate MSRV and demo toolchain are managed separately—developing the macro itself does not require GPUI platform libraries.
Published GPUI 0.2.2 Regression Checks
Section titled “Published GPUI 0.2.2 Regression Checks”A dedicated macOS fixture verifies dynamic string keys, numeric component defaults, mixed root fragments, listener signatures, element identity, and explicit state updates against gpui = "=0.2.2" (with font-kit, runtime_shaders, test-support, and tailwind-scale):
cargo test --manifest-path tests/fixtures/gpui-0.2.2/Cargo.tomlShare One GPUI Type Identity
Section titled “Share One GPUI Type Identity”Use Kit’s unified re-exports through gpui::component, gpui::base, and gpui::platform:
- Call
gpui::init(cx)before opening windows. - Mount roots with
gpui::open_window(...). - Load icons via
application().with_assets(gpui::assets::Assets).
Do not mix direct Zed Git gpui, gpui_platform, or standalone Git component dependencies alongside GPUI Kit—each crate instance defines distinct Rust types that cannot be interchanged.
Verify your dependency tree has a single engine instance:
cargo xtask check-gpuicargo tree --manifest-path demo/Cargo.toml --locked -i gpui-preKeeping Versions in Sync
Section titled “Keeping Versions in Sync”Follow GPUI Kit’s stable releases. The compatibility workflow tracks the latest non-yanked Kit release on crates.io, updates the demo pin, and regenerates the lockfile, API tables, snapshots, specification, and this matrix. GPUI Fast is optional; the verified matrix covers Kit’s default gpui-pre backend.