Skip to content

armgit / cua

Public Imported from GitHub
0

Scale computer-use 2.0 with open-source drivers, cross-OS sandboxes, and benchmarks for training, evaluation, and data generation.

Spaces: plain Linux wizard words, one disk figure, honest time estimate (CUA-2281) (#5933)

cua-agents[bot]403757923da0
diff --git a/apps/cua-spaces-macos/Tests/CuaSpacesMacTests/WizardRunOnTooltipTests.swift b/apps/cua-spaces-macos/Tests/CuaSpacesMacTests/WizardRunOnTooltipTests.swift
index 31eed4e7a6..01e0cba579 100644
--- a/apps/cua-spaces-macos/Tests/CuaSpacesMacTests/WizardRunOnTooltipTests.swift
+++ b/apps/cua-spaces-macos/Tests/CuaSpacesMacTests/WizardRunOnTooltipTests.swift
@@ -29,7 +29,7 @@ struct WizardRunOnTooltipTests {
#expect(v.placementId == "local")
seen[os] = NewSpaceWizardView.runOnHelp(v)
}
- #expect(seen[.linux] == "Container on this Mac (gVisor when installed)")
+ #expect(seen[.linux] == "Linux, on this Mac")
#expect(seen[.windows] == "QEMU virtual machine on this Mac")
#expect(seen[.macos] == "Lume virtual machine (Apple silicon)")
}
diff --git a/apps/cua-spaces-web/e2e/first-space.spec.ts b/apps/cua-spaces-web/e2e/first-space.spec.ts
index 126b4f8b24..4e261a2a0d 100644
--- a/apps/cua-spaces-web/e2e/first-space.spec.ts
+++ b/apps/cua-spaces-web/e2e/first-space.spec.ts
@@ -27,7 +27,7 @@ test("empty home and New Space on the macOS host's answer, loaded before the hos
await expect(page.getByLabel("Filter by state").getByRole("button", { name: "Running" })).toBeVisible();
await expect(home.getByRole("heading")).toHaveText("Create your first Space");
await expect(home).toContainText("Choose a system for your first Space.");
- const linux = home.getByRole("button", { name: "Linux, About 1 minute · 3.2–7.1 GB of disk" });
+ const linux = home.getByRole("button", { name: "Linux, About 3 minutes · 3.3–7.3 GB of disk" });
const macos = home.getByRole("button", { name: "macOS, About 23 GB download" });
await expect(linux).toBeVisible();
await expect(macos).toBeVisible();
diff --git a/apps/cua-spaces-web/e2e/new-space.ts b/apps/cua-spaces-web/e2e/new-space.ts
index 698a9153be..9a26220272 100644
--- a/apps/cua-spaces-web/e2e/new-space.ts
+++ b/apps/cua-spaces-web/e2e/new-space.ts
@@ -187,8 +187,14 @@ async function checkWizard(page: Page, state: WizardState, v: WizardView, menuCh
if (v.streamNote) await expect(root.locator("[data-stream-note]")).toHaveText(v.streamNote);
else await expect(root.locator("[data-stream-note]")).toHaveCount(0);
} else {
- const rows = await root.locator("[data-summary-row]").evaluateAll((els) => els.map((el) => [...el.children].map((c) => c.textContent ?? "")));
- expect(rows).toEqual(v.summary.map((f) => [f.label, f.value]));
+ // The developer-only rows sit under "Advanced" (the page's SUMMARY_ADVANCED), after the plain ones.
+ const technical = new Set(["Image", "Kind", "Architecture", "Runtime"]);
+ const plain = v.summary.filter((f) => !technical.has(f.label));
+ const tech = v.summary.filter((f) => technical.has(f.label));
+ await expect(root.locator("[data-advanced-toggle]")).toHaveCount(tech.length ? 1 : 0);
+ const rowsOf = () =>
+ root.locator("[data-summary-row]").evaluateAll((els) => els.map((el) => [...el.children].map((c) => c.textContent ?? "")));
+ expect(await rowsOf()).toEqual((v.advanced ? [...plain, ...tech] : plain).map((f) => [f.label, f.value]));
}
}
diff --git a/apps/cua-spaces-web/src/__tests__/cli-hints-summary.test.tsx b/apps/cua-spaces-web/src/__tests__/cli-hints-summary.test.tsx
index 24d424e08b..87d8efe55c 100644
--- a/apps/cua-spaces-web/src/__tests__/cli-hints-summary.test.tsx
+++ b/apps/cua-spaces-web/src/__tests__/cli-hints-summary.test.tsx
@@ -46,6 +46,20 @@ async function toSummary(openWhenReady: boolean): Promise<HTMLElement> {
const mount = (cli?: DemoOptions["cli"]) => mountApp("/spaces", { failsCreates: false, listsGhost: false, demo: { cli } });
+describe.skipIf(!wasmBuilt)("New Space's Summary, in plain words", () => {
+ it("keeps the image and engine under Advanced", { timeout: 20_000 }, async () => {
+ await mount();
+ const dialog = await toSummary(false);
+ const text = () => dialog.querySelector("[data-summary]")!.textContent!;
+ expect(text()).toContain("Linux, on this Mac");
+ expect(text()).not.toMatch(/gVisor|ghcr\.io/);
+ expect(dialog.querySelector("[data-summary-advanced]")).toBeNull();
+ fireEvent.click(dialog.querySelector("[data-advanced-toggle]")!);
+ await waitFor(() => expect(dialog.querySelector("[data-summary-advanced]")).not.toBeNull());
+ expect(dialog.querySelector("[data-summary-advanced]")!.textContent).toMatch(/ghcr\.io\/trycua\/linux/);
+ });
+});
+
describe.skipIf(!wasmBuilt)("New Space's Summary, in Terminal", () => {
it("shows the create the wizard would make, under the released app's CLI", { timeout: 20_000 }, async () => {
await mount();
diff --git a/apps/cua-spaces-web/src/__tests__/create-stages.test.tsx b/apps/cua-spaces-web/src/__tests__/create-stages.test.tsx
index 6a5f6982f6..148b018b8f 100644
--- a/apps/cua-spaces-web/src/__tests__/create-stages.test.tsx
+++ b/apps/cua-spaces-web/src/__tests__/create-stages.test.tsx
@@ -85,5 +85,13 @@ describe("a create's stages without the core", () => {
expect(transferText({ bytesDone: 12.4 * GB, bytesTotal: 30 * GB, bytesPerSecond: 85 * 2 ** 20 })).toBe("12.4 of 30.0 GB · 85 MB/s · about 4 min");
expect(transferText({ bytesDone: 420 * 2 ** 20, bytesTotal: 900 * 2 ** 20 })).toBe("420 of 900 MB");
expect(transferText({})).toBeNull();
+ // Nothing is promised without a rate; work after the download counts in the time left.
+ const MB = 2 ** 20;
+ expect(transferText({ bytesDone: 440 * MB, bytesTotal: 456 * MB, bytesPerSecond: 20 * MB })).toMatch(/less than a minute$/);
+ expect(
+ transferText({ bytesDone: 440 * MB, bytesTotal: 456 * MB, bytesPerSecond: 20 * MB }, { bytes: 1100 * MB, secs: 26 }),
+ ).toMatch(/about 1 min$/);
+ expect(transferText({ bytesDone: 0, bytesTotal: 1100 * MB }, { bytes: 0, secs: 26, pace: 9_100_000 })).toMatch(/about 3 min$/);
+ expect(transferText({ bytesDone: MB, bytesTotal: 10 * MB })).toBe("1.0 of 10.0 MB");
});
});
diff --git a/apps/cua-spaces-web/src/bridge/derive.ts b/apps/cua-spaces-web/src/bridge/derive.ts
index 8d02c05b5a..47fa252635 100644
--- a/apps/cua-spaces-web/src/bridge/derive.ts
+++ b/apps/cua-spaces-web/src/bridge/derive.ts
@@ -119,8 +119,24 @@ const PHASE_LABEL: Record<string, string> = {
connecting: "Connecting…",
};
-/** "12.4 of 30.0 GB · 85 MB/s · about 4 min" (`creating::transfer_text`). */
-export function transferText(p: Pick<PendingCreate, "bytesDone" | "bytesTotal" | "bytesPerSecond">): string | null {
+/** What follows a download (`creating::Later`): bytes still to fetch, seconds
+ * of work that move none, and a measured pace to assume until a rate is known. */
+export interface Later {
+ bytes: number;
+ secs: number;
+ pace?: number;
+}
+
+/** Measured on a Mac mini, 25 Oct 2026 (CUA-2281): `wizard::FIRST_RUN_BYTES_PER_SEC`. */
+export const FIRST_RUN_BYTES_PER_SEC = 9_100_000;
+/** `wizard::CACHED_START_SECS`: a Linux Space starting from a cached image. */
+export const CACHED_START_SECS = 6;
+
+/** "12.4 of 30.0 GB · 85 MB/s · about 4 min" (`creating::transfer_text_with`). */
+export function transferText(
+ p: Pick<PendingCreate, "bytesDone" | "bytesTotal" | "bytesPerSecond">,
+ later: Later = { bytes: 0, secs: 0 },
+): string | null {
if (p.bytesDone == null) return null;
const unit = (n: number): [number, string] =>
n >= 2 ** 30 ? [2 ** 30, "GB"] : n >= 2 ** 20 ? [2 ** 20, "MB"] : n >= 1024 ? [1024, "KB"] : [1, "bytes"];
@@ -137,22 +153,24 @@ export function transferText(p: Pick<PendingCreate, "bytesDone" | "bytesTotal" |
const u = unit(p.bytesDone);
out = `${scaled(p.bytesDone, u, 100)} ${u[1]}`;
}
- const rate = p.bytesPerSecond != null && Number.isFinite(p.bytesPerSecond) && p.bytesPerSecond > 0 ? p.bytesPerSecond : null;
- if (rate) {
- const u = unit(Math.floor(rate));
- out += ` · ${scaled(Math.floor(rate), u, 10)} ${u[1]}/s`;
- if (total > 0) {
- const secs = Math.max(0, total - p.bytesDone) / rate;
- const mins = Math.round(secs / 60);
- out +=
- secs < 60
- ? " · less than a minute"
- : mins < 60
- ? ` · about ${mins} min`
- : mins % 60 === 0
- ? ` · about ${mins / 60} h`
- : ` · about ${Math.floor(mins / 60)} h ${mins % 60} min`;
- }
+ const measured = p.bytesPerSecond != null && Number.isFinite(p.bytesPerSecond) && p.bytesPerSecond > 0 ? p.bytesPerSecond : null;
+ if (measured) {
+ const u = unit(Math.floor(measured));
+ out += ` · ${scaled(Math.floor(measured), u, 10)} ${u[1]}/s`;
+ }
+ // Without a rate nothing is promised, unless a measured pace stands in.
+ const pace = measured ?? later.pace ?? null;
+ if (pace && total > 0) {
+ const secs = (Math.max(0, total - p.bytesDone) + later.bytes) / pace + later.secs;
+ const mins = Math.round(secs / 60);
+ out +=
+ secs < 60
+ ? " · less than a minute"
+ : mins < 60
+ ? ` · about ${mins} min`
+ : mins % 60 === 0
+ ? ` · about ${mins / 60} h`
+ : ` · about ${Math.floor(mins / 60)} h ${mins % 60} min`;
}
return out;
}
@@ -276,7 +294,10 @@ function fallbackCompose(spaces: Space[], state: CreatesState): Space[] {
permille: p.permille,
label: p.error ? "Failed" : stageLabel(p),
error: p.error ?? undefined,
- transfer: !p.error && p.phase === "pulling" ? (transferText(p) ?? undefined) : undefined,
+ transfer:
+ !p.error && p.phase === "pulling"
+ ? (transferText(p, p.os === "linux" ? { bytes: 0, secs: CACHED_START_SECS, pace: FIRST_RUN_BYTES_PER_SEC } : { bytes: 0, secs: 0 }) ?? undefined)
+ : undefined,
cancellable: !p.error && !p.cancelling,
cancelling: p.cancelling,
},
diff --git a/apps/cua-spaces-web/src/bridge/new-space.ts b/apps/cua-spaces-web/src/bridge/new-space.ts
index 736172ae4d..ff002373b1 100644
--- a/apps/cua-spaces-web/src/bridge/new-space.ts
+++ b/apps/cua-spaces-web/src/bridge/new-space.ts
@@ -251,7 +251,7 @@ export interface EmptyTile {
os: "linux" | "macos";
/** "Linux", "macOS". */
name: string;
- /** "About 1 minute · 3.2–7.1 GB of disk", "About 22 GB download". */
+ /** "About 3 minutes · 3.3–7.3 GB of disk", "About 22 GB download". */
detail: string;
}
@@ -286,7 +286,10 @@ export function emptyHome(core: CoreClient, hostArch: string | null | undefined,
if (core.status !== "ready") return null;
const c = core.tryCall<EmptyChrome>("window.chrome", {});
if (!c?.emptyLinuxDetail) return null;
- const tiles: EmptyTile[] = [{ os: "linux", name: c.emptyAction, detail: c.emptyLinuxDetail }];
+ // The chrome's Linux line is for the machine the core runs on; the wasm core
+ // cannot tell, so with the host's architecture known the core words it for that.
+ const linuxDetail = hostArch ? (core.tryCall<string>("window.emptyLinuxDetail", { hostArch }) ?? c.emptyLinuxDetail) : c.emptyLinuxDetail;
+ const tiles: EmptyTile[] = [{ os: "linux", name: c.emptyAction, detail: linuxDetail }];
const appleSilicon = !hostArch || ["arm64", "aarch64"].includes(hostArch.toLowerCase());
if (os === "macos" && appleSilicon) tiles.push({ os: "macos", name: c.emptyMacosAction, detail: c.emptyMacosDetail });
return { title: c.emptyTitle, detail: c.emptyDetail, tiles };
diff --git a/apps/cua-spaces-web/src/components/__tests__/empty-home.test.tsx b/apps/cua-spaces-web/src/components/__tests__/empty-home.test.tsx
index 9909af5ab5..5f500c4e5b 100644
--- a/apps/cua-spaces-web/src/components/__tests__/empty-home.test.tsx
+++ b/apps/cua-spaces-web/src/components/__tests__/empty-home.test.tsx
@@ -131,7 +131,7 @@ describe.skipIf(!wasmBuilt)("the empty home (wasm core)", () => {
it("shows the core's figures: Linux's measured time and disk, macOS's catalog download", async () => {
const core = await testCore();
expect(emptyHome(core, "arm64", "macos")!.tiles.map((t) => [t.name, t.detail])).toEqual([
- ["Linux", "About 1 minute · 3.2–7.1 GB of disk"],
+ ["Linux", "About 3 minutes · 3.3–7.3 GB of disk"],
["macOS", "About 23 GB download"],
]);
});
diff --git a/apps/cua-spaces-web/src/components/new-space/new-space-dialog.tsx b/apps/cua-spaces-web/src/components/new-space/new-space-dialog.tsx
index f194241358..513b3a2834 100644
--- a/apps/cua-spaces-web/src/components/new-space/new-space-dialog.tsx
+++ b/apps/cua-spaces-web/src/components/new-space/new-space-dialog.tsx
@@ -678,17 +678,51 @@ function OptionsStep({ v }: { v: WizardView }) {
);
}
+/** The Summary rows only a developer needs (`wizard::SUMMARY_ADVANCED`): they
+ * sit under "Advanced", the same disclosure the System step uses. */
+const SUMMARY_ADVANCED = new Set(["Image", "Kind", "Architecture", "Runtime"]);
+
+function SummaryRow({ fact }: { fact: { label: string; value: string } }) {
+ return (
+ <div data-summary-row="" className="flex items-baseline justify-between gap-6 px-4 py-2 text-[13px]">
+ <span className="shrink-0 text-muted-foreground">{fact.label}</span>
+ <span className={cn("min-w-0 text-right break-all", fact.label === "Image" && "font-mono text-xs")}>{fact.value}</span>
+ </div>
+ );
+}
+
function SummaryStep({ v }: { v: WizardView }) {
+ const { send } = useNewSpaceWizard();
+ const plain = v.summary.filter((f) => !SUMMARY_ADVANCED.has(f.label));
+ const technical = v.summary.filter((f) => SUMMARY_ADVANCED.has(f.label));
return (
<>
<Group data-summary="">
- {v.summary.map((fact) => (
- <div key={fact.label} data-summary-row="" className="flex items-baseline justify-between gap-6 px-4 py-2 text-[13px]">
- <span className="shrink-0 text-muted-foreground">{fact.label}</span>
- <span className={cn("min-w-0 text-right break-all", fact.label === "Image" && "font-mono text-xs")}>{fact.value}</span>
- </div>
+ {plain.map((fact) => (
+ <SummaryRow key={fact.label} fact={fact} />
))}
</Group>
+ {technical.length ? (
+ <div className="mt-4">
+ <button
+ type="button"
+ data-advanced-toggle=""
+ aria-expanded={v.advanced}
+ onClick={() => send({ type: "toggle-advanced" })}
+ className="flex items-center gap-1 px-1 text-xs font-semibold text-muted-foreground outline-none hover:text-foreground focus-visible:text-foreground"
+ >
+ <ChevronRightIcon className={cn("size-3.5 transition-transform", v.advanced && "rotate-90")} />
+ {v.labels.advanced}
+ </button>
+ {v.advanced ? (
+ <Group className="mt-2" data-summary-advanced="">
+ {technical.map((fact) => (
+ <SummaryRow key={fact.label} fact={fact} />
+ ))}
+ </Group>
+ ) : null}
+ </div>
+ ) : null}
<SummaryCommands v={v} />
</>
);
diff --git a/apps/cua-spaces/src/components/desktop/MainWindow.test.tsx b/apps/cua-spaces/src/components/desktop/MainWindow.test.tsx
index 304f7562e3..a31bd615f8 100644
--- a/apps/cua-spaces/src/components/desktop/MainWindow.test.tsx
+++ b/apps/cua-spaces/src/components/desktop/MainWindow.test.tsx
@@ -566,7 +566,7 @@ describe("empty home", () => {
expect(await screen.findByRole("heading", { name: "No Spaces yet" })).toBeInTheDocument();
expect(screen.getByText("Choose a system for your first Space.")).toBeInTheDocument();
expect(screen.queryByRole("heading", { name: "This computer" })).toBeNull();
- expect(screen.getByRole("button", { name: "Linux, About 1 minute · 3.2–7.1 GB of disk" })).toBeInTheDocument();
+ expect(screen.getByRole("button", { name: "Linux, About 3 minutes · 3.3–7.3 GB of disk" })).toBeInTheDocument();
expect(screen.getByRole("button", { name: /^macOS, About .+ download$/ })).toBeInTheDocument();
});
diff --git a/apps/cua-spaces/src/components/desktop/NewSpaceWizard.test.tsx b/apps/cua-spaces/src/components/desktop/NewSpaceWizard.test.tsx
index f267300dce..05875c9662 100644
--- a/apps/cua-spaces/src/components/desktop/NewSpaceWizard.test.tsx
+++ b/apps/cua-spaces/src/components/desktop/NewSpaceWizard.test.tsx
@@ -319,7 +319,7 @@ describe("the Resources step", () => {
next();
const p = size("ghcr.io/trycua/linux:24.04", "arm64");
const gb = (b: number) => (b / GB < 10 ? (b / GB).toFixed(1) : Math.round(b / GB)) + " GB";
- expect(facts()).toEqual(["Container", "ARM", `${gb(p.unpacked)}–${gb(p.unpacked + p.disk + p.download)} initially; grows with use (download ${gb(p.download)})`, "40 GB on Colima"]);
+ expect(facts()).toEqual(["Container", "ARM", `${gb(p.unpacked).replace(" GB", "")}–${gb(p.unpacked + p.disk + p.download)} initially; grows with use (download ${gb(p.download)})`, "40 GB on Colima"]);
expect(screen.queryByRole("slider", { name: "Disk" })).toBeNull();
expect(screen.getByRole("button", { name: "Continue" })).toBeEnabled();
});
@@ -338,7 +338,7 @@ describe("the Resources step", () => {
expect(screen.getByText(/includes 455 MB one-time Linux runtime download/)).toBeInTheDocument();
expect(screen.queryByText("Linux runtime")).toBeNull();
expect(screen.getAllByText("Disk")).toHaveLength(1);
- expect(screen.getByText(/GB–.*GB initially; grows with use/)).toBeInTheDocument();
+ expect(screen.getByText(/GB initially; grows with use/)).toBeInTheDocument();
});
it("blocks Continue in one line when the Space does not fit", () => {
diff --git a/libs/cua/crates/cua-spaces-app-core/parity/golden/create-gpu.json b/libs/cua/crates/cua-spaces-app-core/parity/golden/create-gpu.json
index c205d7960f..55c22026dd 100644
--- a/libs/cua/crates/cua-spaces-app-core/parity/golden/create-gpu.json
+++ b/libs/cua/crates/cua-spaces-app-core/parity/golden/create-gpu.json
@@ -48,7 +48,7 @@
"resourceFacts": [
"Kind: Container",
"Architecture: ARM",
- "Disk: 2.9 GB–6.9 GB initially; grows with use"
+ "Disk: 2.9–6.9 GB initially; grows with use"
],
"resourcesError": null,
"runtime": "auto",
@@ -266,7 +266,7 @@
"resourceFacts": [
"Kind: Container",
"Architecture: ARM",
- "Disk: 2.9 GB–6.9 GB initially; grows with use"
+ "Disk: 2.9–6.9 GB initially; grows with use"
],
"resourcesError": null,
"runtime": "auto",
diff --git a/libs/cua/crates/cua-spaces-app-core/parity/golden/create-resources.json b/libs/cua/crates/cua-spaces-app-core/parity/golden/create-resources.json
index b6b31f7b7d..36b5515051 100644
--- a/libs/cua/crates/cua-spaces-app-core/parity/golden/create-resources.json
+++ b/libs/cua/crates/cua-spaces-app-core/parity/golden/create-resources.json
@@ -48,7 +48,7 @@
"resourceFacts": [
"Kind: Container",
"Architecture: ARM",
- "Disk: 3.3 GB–7.3 GB initially; grows with use (download 1.1 GB); includes 456 MB one-time Linux runtime download, shared by Linux Spaces",
+ "Disk: 3.3–7.3 GB initially; grows with use (download 1.1 GB); includes 456 MB one-time Linux runtime download, shared by Linux Spaces",
"Available: 3.0 GB on Colima"
],
"resourcesError": "Not enough space on Colima: needs 9.4 GB, 3.0 GB available.",
@@ -104,7 +104,7 @@
"resourceFacts": [
"Kind: Container",
"Architecture: ARM",
- "Disk: 3.3 GB–7.3 GB initially; grows with use (download 1.1 GB); includes 456 MB one-time Linux runtime download, shared by Linux Spaces",
+ "Disk: 3.3–7.3 GB initially; grows with use (download 1.1 GB); includes 456 MB one-time Linux runtime download, shared by Linux Spaces",
"Available: 3.0 GB on Colima"
],
"resourcesError": "Not enough space on Colima: needs 9.4 GB, 3.0 GB available.",
@@ -165,7 +165,7 @@
"resourceFacts": [
"Kind: Container",
"Architecture: ARM",
- "Disk: 3.3 GB–7.3 GB initially; grows with use (download 1.1 GB); includes 456 MB one-time Linux runtime download, shared by Linux Spaces",
+ "Disk: 3.3–7.3 GB initially; grows with use (download 1.1 GB); includes 456 MB one-time Linux runtime download, shared by Linux Spaces",
"Available: 3.0 GB on Colima"
],
"resourcesError": "Not enough space on Colima: needs 9.4 GB, 3.0 GB available.",
@@ -226,7 +226,7 @@
"resourceFacts": [
"Kind: Container",
"Architecture: ARM",
- "Disk: 1.6 GB–3.3 GB initially; grows with use; includes 456 MB one-time Linux runtime download, shared by Linux Spaces",
+ "Disk: 1.6–3.3 GB initially; grows with use; includes 456 MB one-time Linux runtime download, shared by Linux Spaces",
"Available: 3.0 GB on Colima"
],
"resourcesError": "Not enough space on Colima: needs 5.4 GB, 3.0 GB available.",
@@ -282,7 +282,7 @@
"resourceFacts": [
"Kind: Container",
"Architecture: ARM",
- "Disk: 1.6 GB–3.3 GB initially; grows with use; includes 456 MB one-time Linux runtime download, shared by Linux Spaces",
+ "Disk: 1.6–3.3 GB initially; grows with use; includes 456 MB one-time Linux runtime download, shared by Linux Spaces",
"Available: 3.0 GB on Colima"
],
"resourcesError": "Not enough space on Colima: needs 5.4 GB, 3.0 GB available.",
@@ -343,7 +343,7 @@
"resourceFacts": [
"Kind: Container",
"Architecture: ARM",
- "Disk: 1.6 GB–3.3 GB initially; grows with use; includes 456 MB one-time Linux runtime download, shared by Linux Spaces",
+ "Disk: 1.6–3.3 GB initially; grows with use; includes 456 MB one-time Linux runtime download, shared by Linux Spaces",
"Available: 3.0 GB on Colima"
],
"resourcesError": "Not enough space on Colima: needs 5.4 GB, 3.0 GB available.",
diff --git a/libs/cua/crates/cua-spaces-app-core/parity/golden/create-space.json b/libs/cua/crates/cua-spaces-app-core/parity/golden/create-space.json
index c8c0789973..671e8e9c93 100644
--- a/libs/cua/crates/cua-spaces-app-core/parity/golden/create-space.json
+++ b/libs/cua/crates/cua-spaces-app-core/parity/golden/create-space.json
@@ -47,7 +47,7 @@
"ranges": "cpus 1-8, memory 2-16",
"resourceFacts": [
"Kind: Container",
- "Disk: 3.0 GB–7.2 GB initially; grows with use"
+ "Disk: 3.0–7.2 GB initially; grows with use"
],
"resourcesError": null,
"runtime": "auto",
@@ -163,7 +163,7 @@
"ranges": "cpus 1-8, memory 2-16",
"resourceFacts": [
"Kind: Container",
- "Disk: 3.0 GB–7.2 GB initially; grows with use"
+ "Disk: 3.0–7.2 GB initially; grows with use"
],
"resourcesError": null,
"runtime": "auto",
@@ -222,7 +222,7 @@
"ranges": "cpus 1-8, memory 2-16",
"resourceFacts": [
"Kind: Container",
- "Disk: 3.0 GB–7.2 GB initially; grows with use"
+ "Disk: 3.0–7.2 GB initially; grows with use"
],
"resourcesError": null,
"runtime": "auto",
@@ -281,7 +281,7 @@
"ranges": "cpus 1-8, memory 2-16",
"resourceFacts": [
"Kind: Container",
- "Disk: 3.0 GB–7.2 GB initially; grows with use"
+ "Disk: 3.0–7.2 GB initially; grows with use"
],
"resourcesError": null,
"runtime": "auto",
@@ -340,7 +340,7 @@
"ranges": "cpus 1-8, memory 2-16",
"resourceFacts": [
"Kind: Container",
- "Disk: 3.0 GB–7.2 GB initially; grows with use"
+ "Disk: 3.0–7.2 GB initially; grows with use"
],
"resourcesError": null,
"runtime": "auto",
@@ -456,7 +456,7 @@
"ranges": "cpus 1-8, memory 2-16",
"resourceFacts": [
"Kind: Container",
- "Disk: 3.0 GB–7.2 GB initially; grows with use"
+ "Disk: 3.0–7.2 GB initially; grows with use"
],
"resourcesError": null,
"runtime": "auto",
@@ -515,7 +515,7 @@
"ranges": "cpus 1-8, memory 2-16",
"resourceFacts": [
"Kind: Container",
- "Disk: 3.0 GB–7.2 GB initially; grows with use"
+ "Disk: 3.0–7.2 GB initially; grows with use"
],
"resourcesError": null,
"runtime": "gvisor",
@@ -581,7 +581,7 @@
"ranges": "cpus 1-8, memory 2-16",
"resourceFacts": [
"Kind: Container",
- "Disk: 3.0 GB–7.2 GB initially; grows with use"
+ "Disk: 3.0–7.2 GB initially; grows with use"
],
"resourcesError": null,
"runtime": "gvisor",
@@ -647,7 +647,7 @@
"ranges": "cpus 1-8, memory 2-16",
"resourceFacts": [
"Kind: Container",
- "Disk: 3.0 GB–7.2 GB initially; grows with use"
+ "Disk: 3.0–7.2 GB initially; grows with use"
],
"resourcesError": null,
"runtime": "gvisor",
@@ -713,7 +713,7 @@
"ranges": "cpus 1-8, memory 2-16",
"resourceFacts": [
"Kind: Container",
- "Disk: 3.0 GB–7.2 GB initially; grows with use"
+ "Disk: 3.0–7.2 GB initially; grows with use"
],
"resourcesError": null,
"runtime": "gvisor",
@@ -772,7 +772,7 @@
"ranges": "cpus 1-8, memory 2-16",
"resourceFacts": [
"Kind: Container",
- "Disk: 3.0 GB–7.2 GB initially; grows with use"
+ "Disk: 3.0–7.2 GB initially; grows with use"
],
"resourcesError": null,
"runtime": "gvisor",
@@ -1181,7 +1181,7 @@
"ranges": "cpus 1-8, memory 2-16",
"resourceFacts": [
"Kind: Container",
- "Disk: 3.0 GB–7.2 GB initially; grows with use"
+ "Disk: 3.0–7.2 GB initially; grows with use"
],
"resourcesError": null,
"runtime": "gvisor",
@@ -2179,7 +2179,7 @@
"summary": [
"System: Linux",
"Image: ghcr.io/acme/desktop:1.2",
- "Runs on: This Mac",
+ "Runs on: Linux, on this Mac",
"Kind: Container",
"Runtime: gVisor container on this Mac",
"Resources: 4 cores, 8 GB memory",
diff --git a/libs/cua/crates/cua-spaces-app-core/parity/golden/experiments.json b/libs/cua/crates/cua-spaces-app-core/parity/golden/experiments.json
index 8471e2addb..7ac0626f73 100644
--- a/libs/cua/crates/cua-spaces-app-core/parity/golden/experiments.json
+++ b/libs/cua/crates/cua-spaces-app-core/parity/golden/experiments.json
@@ -107,7 +107,7 @@
"placements": [
"auto | Auto | Least-loaded of your machines: this Mac or one of your machines that provides Spaces. | on",
"---",
- "local | This Mac | Container on this Mac (gVisor when installed) | on *",
+ "local | This Mac | Linux, on this Mac | on *",
"---",
"host:m-mini | Mac mini | Through the Cua relay | on",
"---",
@@ -242,7 +242,7 @@
"placements": [
"auto | Auto | Least-loaded of your machines: this Mac or one of your machines that provides Spaces. | on",
"---",
- "local | This Mac | Container on this Mac (gVisor when installed) | on *",
+ "local | This Mac | Linux, on this Mac | on *",
"---",
"host:m-mini | Mac mini | Through the Cua relay | on",
"---",
@@ -375,7 +375,7 @@
"placements": [
"auto | Auto | Least-loaded of your machines: this Mac or one of your machines that provides Spaces. | on",
"---",
- "local | This Mac | Container on this Mac (gVisor when installed) | on *",
+ "local | This Mac | Linux, on this Mac | on *",
"---",
"host:m-mini | Mac mini | Through the Cua relay | on"
]
@@ -493,7 +493,7 @@
"placements": [
"auto | Auto | Least-loaded of your machines: this Mac or one of your machines that provides Spaces. | on",
"---",
- "local | This Mac | Container on this Mac (gVisor when installed) | on *",
+ "local | This Mac | Linux, on this Mac | on *",
"---",
"host:m-mini | Mac mini | Through the Cua relay | on"
]
@@ -611,7 +611,7 @@
"placements": [
"auto | Auto | Least-loaded of your machines: this Mac or one of your machines that provides Spaces. | on",
"---",
- "local | This Mac | Container on this Mac (gVisor when installed) | on *",
+ "local | This Mac | Linux, on this Mac | on *",
"---",
"host:m-mini | Mac mini | Through the Cua relay | on"
]
@@ -729,7 +729,7 @@
"placements": [
"auto | Auto | Least-loaded of your machines: this Mac or one of your machines that provides Spaces. | on",
"---",
- "local | This Mac | Container on this Mac (gVisor when installed) | on *",
+ "local | This Mac | Linux, on this Mac | on *",
"---",
"host:m-mini | Mac mini | Through the Cua relay | on"
]
@@ -852,7 +852,7 @@
"placements": [
"auto | Auto | Least-loaded of your machines: this Mac or one of your machines that provides Spaces. | on",
"---",
- "local | This Mac | Container on this Mac (gVisor when installed) | on *",
+ "local | This Mac | Linux, on this Mac | on *",
"---",
"host:m-mini | Mac mini | Through the Cua relay | on"
]
@@ -977,7 +977,7 @@
"placements": [
"auto | Auto | Least-loaded of your machines: this Mac or one of your machines that provides Spaces. | on",
"---",
- "local | This Mac | Container on this Mac (gVisor when installed) | on *",
+ "local | This Mac | Linux, on this Mac | on *",
"---",
"host:m-mini | Mac mini | Through the Cua relay | on",
"---",
@@ -1102,7 +1102,7 @@
"placements": [
"auto | Auto | Least-loaded of your machines: this Mac or one of your machines that provides Spaces. | on",
"---",
- "local | This Mac | Container on this Mac (gVisor when installed) | on *",
+ "local | This Mac | Linux, on this Mac | on *",
"---",
"host:m-mini | Mac mini | Through the Cua relay | on",
"---",
@@ -1228,7 +1228,7 @@
"placements": [
"auto | Auto | Least-loaded of your machines: this Mac or one of your machines that provides Spaces. | on",
"---",
- "local | This Mac | Container on this Mac (gVisor when installed) | on *",
+ "local | This Mac | Linux, on this Mac | on *",
"---",
"host:m-mini | Mac mini | Through the Cua relay | on",
"---",
@@ -1353,7 +1353,7 @@
"placements": [
"auto | Auto | Least-loaded of your machines: this Mac or one of your machines that provides Spaces. | on",
"---",
- "local | This Mac | Container on this Mac (gVisor when installed) | on *",
+ "local | This Mac | Linux, on this Mac | on *",
"---",
"host:m-mini | Mac mini | Through the Cua relay | on",
"---",
diff --git a/libs/cua/crates/cua-spaces-app-core/parity/golden/main-window.json b/libs/cua/crates/cua-spaces-app-core/parity/golden/main-window.json
index 04afa41e3c..65e3b0579d 100644
--- a/libs/cua/crates/cua-spaces-app-core/parity/golden/main-window.json
+++ b/libs/cua/crates/cua-spaces-app-core/parity/golden/main-window.json
@@ -581,7 +581,7 @@
"account: Not signed in",
"signIn: Sign in",
"settings: Settings ⌘,",
- "empty: No Spaces yet / Choose a system for your first Space. / Linux (About 1 minute · 3.2–7.1 GB of disk) / macOS (About 23 GB download)",
+ "empty: No Spaces yet / Choose a system for your first Space. / Linux (About 3 minutes · 3.3–7.3 GB of disk) / macOS (About 23 GB download)",
"volume: Volume"
]
},
@@ -594,7 +594,7 @@
"account: API key",
"signIn: -",
"settings: Settings ⌘,",
- "empty: No Spaces yet / Choose a system for your first Space. / Linux (About 1 minute · 3.2–7.1 GB of disk) / macOS (About 23 GB download)",
+ "empty: No Spaces yet / Choose a system for your first Space. / Linux (About 3 minutes · 3.3–7.3 GB of disk) / macOS (About 23 GB download)",
"volume: Volume"
]
},
@@ -607,7 +607,7 @@
"account: [email protected]",
"signIn: -",
"settings: Settings ⌘,",
- "empty: No Spaces yet / Choose a system for your first Space. / Linux (About 1 minute · 3.2–7.1 GB of disk) / macOS (About 23 GB download)",
+ "empty: No Spaces yet / Choose a system for your first Space. / Linux (About 3 minutes · 3.3–7.3 GB of disk) / macOS (About 23 GB download)",
"volume: Volume"
]
},
diff --git a/libs/cua/crates/cua-spaces-app-core/parity/golden/placement-picker.json b/libs/cua/crates/cua-spaces-app-core/parity/golden/placement-picker.json
index 5914b9e50c..5743a30afb 100644
--- a/libs/cua/crates/cua-spaces-app-core/parity/golden/placement-picker.json
+++ b/libs/cua/crates/cua-spaces-app-core/parity/golden/placement-picker.json
@@ -21,7 +21,7 @@
"placements": [
"auto | Auto | Least-loaded of your machines: this Mac or one of your machines that provides Spaces. | on",
"---",
- "local | This Mac | Container on this Mac (gVisor when installed) | on *",
+ "local | This Mac | Linux, on this Mac | on *",
"---",
"host:m-mini | Mac mini | Through the Cua relay | on",
"host:lab | lab | Over Tailscale or your network | on",
@@ -31,18 +31,18 @@
"resourceFacts": [
"Kind: Container",
"Architecture: ARM",
- "Disk: 2.9 GB–6.9 GB initially; grows with use"
+ "Disk: 2.9–6.9 GB initially; grows with use"
],
"step": 0,
"summary": [
"System: Ubuntu 24.04",
"Image: ghcr.io/trycua/linux:24.04",
- "Runs on: This Mac",
+ "Runs on: Linux, on this Mac",
"Kind: Container",
"Architecture: ARM",
"Runtime: Container on this Mac (gVisor when installed)",
"Resources: 2 cores, 4 GB memory",
- "Disk: 2.9 GB–6.9 GB initially; grows with use",
+ "Disk: 2.9–6.9 GB initially; grows with use",
"Name: space-000000002a",
"When ready: Open the desktop"
],
@@ -71,7 +71,7 @@
"placements": [
"auto | Auto | Least-loaded of your machines: this Mac or one of your machines that provides Spaces. | on",
"---",
- "local | This Mac | Container on this Mac (gVisor when installed) | on *",
+ "local | This Mac | Linux, on this Mac | on *",
"---",
"host:m-mini | Mac mini | Through the Cua relay | on",
"host:lab | lab | Over Tailscale or your network | on",
@@ -81,18 +81,18 @@
"resourceFacts": [
"Kind: Container",
"Architecture: ARM",
- "Disk: 2.9 GB–6.9 GB initially; grows with use"
+ "Disk: 2.9–6.9 GB initially; grows with use"
],
"step": 0,
"summary": [
"System: Ubuntu 24.04",
"Image: ghcr.io/trycua/linux:24.04",
- "Runs on: This Mac",
+ "Runs on: Linux, on this Mac",
"Kind: Container",
"Architecture: ARM",
"Runtime: Container on this Mac (gVisor when installed)",
"Resources: 2 cores, 4 GB memory",
- "Disk: 2.9 GB–6.9 GB initially; grows with use",
+ "Disk: 2.9–6.9 GB initially; grows with use",
"Name: space-000000002a",
"When ready: Open the desktop"
],
@@ -121,7 +121,7 @@
"placements": [
"auto | Auto | Least-loaded of your machines: this Mac or one of your machines that provides Spaces. | on",
"---",
- "local | This Mac | Container on this Mac (gVisor when installed) | on *",
+ "local | This Mac | Linux, on this Mac | on *",
"---",
"host:m-mini | Mac mini | Through the Cua relay | on",
"host:lab | lab | Over Tailscale or your network | on",
@@ -131,18 +131,18 @@
"resourceFacts": [
"Kind: Container",
"Architecture: ARM",
- "Disk: 2.9 GB–6.9 GB initially; grows with use"
+ "Disk: 2.9–6.9 GB initially; grows with use"
],
"step": 0,
"summary": [
"System: Ubuntu 24.04",
"Image: ghcr.io/trycua/linux:24.04",
- "Runs on: This Mac",
+ "Runs on: Linux, on this Mac",
"Kind: Container",
"Architecture: ARM",
"Runtime: Container on this Mac (gVisor when installed)",
"Resources: 2 cores, 4 GB memory",
- "Disk: 2.9 GB–6.9 GB initially; grows with use",
+ "Disk: 2.9–6.9 GB initially; grows with use",
"Name: space-000000002a",
"When ready: Open the desktop"
],
@@ -171,7 +171,7 @@
"placements": [
"auto | Auto | Least-loaded of your machines: this Mac or one of your machines that provides Spaces. | on",
"---",
- "local | This Mac | Container on this Mac (gVisor when installed) | on",
+ "local | This Mac | Linux, on this Mac | on",
"---",
"host:m-mini | Mac mini | Through the Cua relay | on *",
"host:lab | lab | Over Tailscale or your network | on",
@@ -180,7 +180,7 @@
"price": null,
"resourceFacts": [
"Kind: Container",
- "Disk: 3.0 GB–7.2 GB initially; grows with use"
+ "Disk: 3.0–7.2 GB initially; grows with use"
],
"step": 0,
"summary": [
@@ -267,7 +267,7 @@
"placements": [
"auto | Auto | Least-loaded of your machines: this Mac or one of your machines that provides Spaces. | on",
"---",
- "local | This Mac | Container on this Mac (gVisor when installed) | on",
+ "local | This Mac | Linux, on this Mac | on",
"---",
"host:m-mini | Mac mini | Through the Cua relay | on *",
"host:lab | lab | Over Tailscale or your network | on",
@@ -276,7 +276,7 @@
"price": null,
"resourceFacts": [
"Kind: Container",
- "Disk: 3.0 GB–7.2 GB initially; grows with use"
+ "Disk: 3.0–7.2 GB initially; grows with use"
],
"step": 0,
"summary": [
@@ -314,7 +314,7 @@
"placements": [
"auto | Auto | Least-loaded of your machines: this Mac or one of your machines that provides Spaces. | on",
"---",
- "local | This Mac | Container on this Mac (gVisor when installed) | on",
+ "local | This Mac | Linux, on this Mac | on",
"---",
"host:m-mini | Mac mini | Through the Cua relay | on",
"host:lab | lab | Over Tailscale or your network | on *",
@@ -323,7 +323,7 @@
"price": null,
"resourceFacts": [
"Kind: Container",
- "Disk: 3.0 GB–7.2 GB initially; grows with use"
+ "Disk: 3.0–7.2 GB initially; grows with use"
],
"step": 0,
"summary": [
@@ -362,7 +362,7 @@
"placements": [
"auto | Auto | Least-loaded of your machines: this Mac or one of your machines that provides Spaces. | on",
"---",
- "local | This Mac | Container on this Mac (gVisor when installed) | on",
+ "local | This Mac | Linux, on this Mac | on",
"---",
"host:m-mini | Mac mini | Through the Cua relay | on",
"host:lab | lab | Over Tailscale or your network | on *",
@@ -373,7 +373,7 @@
"price": null,
"resourceFacts": [
"Kind: Container",
- "Disk: 3.0 GB–7.2 GB initially; grows with use"
+ "Disk: 3.0–7.2 GB initially; grows with use"
],
"step": 0,
"summary": [
@@ -414,7 +414,7 @@
"placements": [
"auto | Auto | Least-loaded of your machines: this Mac or one of your machines that provides Spaces. | on",
"---",
- "local | This Mac | Container on this Mac (gVisor when installed) | on",
+ "local | This Mac | Linux, on this Mac | on",
"---",
"host:m-mini | Mac mini | Through the Cua relay | on",
"host:lab | lab | Over Tailscale or your network | on",
@@ -466,7 +466,7 @@
"placements": [
"auto | Auto | Least-loaded of your machines: this Mac or one of your machines that provides Spaces. | on",
"---",
- "local | This Mac | Container on this Mac (gVisor when installed) | on *",
+ "local | This Mac | Linux, on this Mac | on *",
"---",
"host:m-mini | Mac mini | Through the Cua relay | on",
"host:lab | lab | Over Tailscale or your network | on",
@@ -476,18 +476,18 @@
"resourceFacts": [
"Kind: Container",
"Architecture: ARM",
- "Disk: 2.9 GB–6.9 GB initially; grows with use"
+ "Disk: 2.9–6.9 GB initially; grows with use"
],
"step": 0,
"summary": [
"System: Ubuntu 24.04",
"Image: ghcr.io/trycua/linux:24.04",
- "Runs on: This Mac",
+ "Runs on: Linux, on this Mac",
"Kind: Container",
"Architecture: ARM",
"Runtime: Container on this Mac (gVisor when installed)",
"Resources: 2 cores, 4 GB memory",
- "Disk: 2.9 GB–6.9 GB initially; grows with use",
+ "Disk: 2.9–6.9 GB initially; grows with use",
"Name: space-000000002a",
"When ready: Open the desktop"
],
@@ -516,7 +516,7 @@
"placements": [
"auto | Auto | Least-loaded of your machines: this Mac or one of your machines that provides Spaces. | on",
"---",
- "local | This Mac | Container on this Mac (gVisor when installed) | on",
+ "local | This Mac | Linux, on this Mac | on",
"---",
"host:m-mini | Mac mini | Through the Cua relay | on *",
"host:lab | lab | Over Tailscale or your network | on",
@@ -525,7 +525,7 @@
"price": null,
"resourceFacts": [
"Kind: Container",
- "Disk: 3.0 GB–7.2 GB initially; grows with use"
+ "Disk: 3.0–7.2 GB initially; grows with use"
],
"step": 0,
"summary": [
@@ -559,7 +559,7 @@
"placements": [
"auto | Auto | Least-loaded of your machines: this Mac or one of your machines that provides Spaces. | on",
"---",
- "local | This Mac | Container on this Mac (gVisor when installed) | on",
+ "local | This Mac | Linux, on this Mac | on",
"---",
"host:m-mini | Mac mini | Through the Cua relay | on *",
"host:lab | lab | Over Tailscale or your network | on",
@@ -568,7 +568,7 @@
"price": null,
"resourceFacts": [
"Kind: Container",
- "Disk: 3.0 GB–7.2 GB initially; grows with use"
+ "Disk: 3.0–7.2 GB initially; grows with use"
],
"step": 1,
"summary": [
@@ -602,7 +602,7 @@
"placements": [
"auto | Auto | Least-loaded of your machines: this Mac or one of your machines that provides Spaces. | on",
"---",
- "local | This Mac | Container on this Mac (gVisor when installed) | on",
+ "local | This Mac | Linux, on this Mac | on",
"---",
"host:m-mini | Mac mini | Through the Cua relay | on *",
"host:lab | lab | Over Tailscale or your network | on",
@@ -611,7 +611,7 @@
"price": null,
"resourceFacts": [
"Kind: Container",
- "Disk: 3.0 GB–7.2 GB initially; grows with use"
+ "Disk: 3.0–7.2 GB initially; grows with use"
],
"step": 2,
"summary": [
@@ -642,7 +642,7 @@
"placements": [
"auto | Auto | Least-loaded of your machines: this Mac or one of your machines that provides Spaces. | on",
"---",
- "local | This Mac | Container on this Mac (gVisor when installed) | on",
+ "local | This Mac | Linux, on this Mac | on",
"---",
"host:m-mini | Mac mini | Through the Cua relay | on *",
"host:lab | lab | Over Tailscale or your network | on",
@@ -651,7 +651,7 @@
"price": null,
"resourceFacts": [
"Kind: Container",
- "Disk: 3.0 GB–7.2 GB initially; grows with use"
+ "Disk: 3.0–7.2 GB initially; grows with use"
],
"step": 3,
"summary": [
@@ -680,24 +680,24 @@
"placement": "local",
"placementError": null,
"placements": [
- "local | This Mac | Container on this Mac (gVisor when installed) | on *"
+ "local | This Mac | Linux, on this Mac | on *"
],
"price": null,
"resourceFacts": [
"Kind: Container",
"Architecture: ARM",
- "Disk: 2.9 GB–6.9 GB initially; grows with use"
+ "Disk: 2.9–6.9 GB initially; grows with use"
],
"step": 3,
"summary": [
"System: Ubuntu 24.04",
"Image: ghcr.io/trycua/linux:24.04",
- "Runs on: This Mac",
+ "Runs on: Linux, on this Mac",
"Kind: Container",
"Architecture: ARM",
"Runtime: Container on this Mac (gVisor when installed)",
"Resources: 2 cores, 4 GB memory",
- "Disk: 2.9 GB–6.9 GB initially; grows with use",
+ "Disk: 2.9–6.9 GB initially; grows with use",
"Name: space-000000002a",
"When ready: Open the desktop"
],
@@ -717,24 +717,24 @@
"placement": "local",
"placementError": null,
"placements": [
- "local | This Mac | Container on this Mac (gVisor when installed) | on *"
+ "local | This Mac | Linux, on this Mac | on *"
],
"price": null,
"resourceFacts": [
"Kind: Container",
"Architecture: ARM",
- "Disk: 2.9 GB–6.9 GB initially; grows with use"
+ "Disk: 2.9–6.9 GB initially; grows with use"
],
"step": 3,
"summary": [
"System: Ubuntu 24.04",
"Image: ghcr.io/trycua/linux:24.04",
- "Runs on: This Mac",
+ "Runs on: Linux, on this Mac",
"Kind: Container",
"Architecture: ARM",
"Runtime: Container on this Mac (gVisor when installed)",
"Resources: 2 cores, 4 GB memory",
- "Disk: 2.9 GB–6.9 GB initially; grows with use",
+ "Disk: 2.9–6.9 GB initially; grows with use",
"Name: space-000000002a",
"When ready: Open the desktop"
],
diff --git a/libs/cua/crates/cua-spaces-app-core/parity/golden/your-cloud.json b/libs/cua/crates/cua-spaces-app-core/parity/golden/your-cloud.json
index 4fc16d9d07..c787c8fd95 100644
--- a/libs/cua/crates/cua-spaces-app-core/parity/golden/your-cloud.json
+++ b/libs/cua/crates/cua-spaces-app-core/parity/golden/your-cloud.json
@@ -20,24 +20,24 @@
"placement": "local",
"placementError": null,
"placements": [
- "local | This Mac | Container on this Mac (gVisor when installed) | on *"
+ "local | This Mac | Linux, on this Mac | on *"
],
"price": null,
"resourceFacts": [
"Kind: Container",
"Architecture: ARM",
- "Disk: 2.9 GB–6.9 GB initially; grows with use"
+ "Disk: 2.9–6.9 GB initially; grows with use"
],
"step": 0,
"summary": [
"System: Ubuntu 24.04",
"Image: ghcr.io/trycua/linux:24.04",
- "Runs on: This Mac",
+ "Runs on: Linux, on this Mac",
"Kind: Container",
"Architecture: ARM",
"Runtime: Container on this Mac (gVisor when installed)",
"Resources: 2 cores, 4 GB memory",
- "Disk: 2.9 GB–6.9 GB initially; grows with use",
+ "Disk: 2.9–6.9 GB initially; grows with use",
"Name: space-000000002a",
"When ready: Open the desktop"
],
@@ -65,24 +65,24 @@
"placement": "local",
"placementError": null,
"placements": [
- "local | This Mac | Container on this Mac (gVisor when installed) | on *"
+ "local | This Mac | Linux, on this Mac | on *"
],
"price": null,
"resourceFacts": [
"Kind: Container",
"Architecture: ARM",
- "Disk: 2.9 GB–6.9 GB initially; grows with use"
+ "Disk: 2.9–6.9 GB initially; grows with use"
],
"step": 0,
"summary": [
"System: Ubuntu 24.04",
"Image: ghcr.io/trycua/linux:24.04",
- "Runs on: This Mac",
+ "Runs on: Linux, on this Mac",
"Kind: Container",
"Architecture: ARM",
"Runtime: Container on this Mac (gVisor when installed)",
"Resources: 2 cores, 4 GB memory",
- "Disk: 2.9 GB–6.9 GB initially; grows with use",
+ "Disk: 2.9–6.9 GB initially; grows with use",
"Name: space-000000002a",
"When ready: Open the desktop"
],
@@ -701,7 +701,7 @@
"placement": "yours",
"placementError": null,
"placements": [
- "local | This Mac | Container on this Mac (gVisor when installed) | on",
+ "local | This Mac | Linux, on this Mac | on",
"---",
"aws | AWS · us-west-2 | t4g.medium, about $0.04/hour | on *"
],
@@ -742,7 +742,7 @@
"placement": "yours",
"placementError": null,
"placements": [
- "local | This Mac | Container on this Mac (gVisor when installed) | on",
+ "local | This Mac | Linux, on this Mac | on",
"---",
"aws | AWS · us-west-2 | t4g.medium, about $0.04/hour | on *"
],
@@ -786,7 +786,7 @@
"placement": "yours",
"placementError": null,
"placements": [
- "local | This Mac | Container on this Mac (gVisor when installed) | on",
+ "local | This Mac | Linux, on this Mac | on",
"---",
"aws | AWS · us-west-2 | t4g.medium, about $0.04/hour | on *"
],
@@ -827,7 +827,7 @@
"placement": "yours",
"placementError": null,
"placements": [
- "local | This Mac | Container on this Mac (gVisor when installed) | on",
+ "local | This Mac | Linux, on this Mac | on",
"---",
"aws | AWS · us-west-2 | t4g.medium, about $0.04/hour | on *"
],
@@ -871,7 +871,7 @@
"placement": "yours",
"placementError": null,
"placements": [
- "local | This Mac | Container on this Mac (gVisor when installed) | on",
+ "local | This Mac | Linux, on this Mac | on",
"---",
"aws | AWS · us-west-2 | t4g.medium, about $0.04/hour | on *",
"modal | Modal · cua-byoc | 2 CPU, 4 GiB, about $0.10/hour | on"
@@ -916,7 +916,7 @@
"placement": "yours",
"placementError": null,
"placements": [
- "local | This Mac | Container on this Mac (gVisor when installed) | on",
+ "local | This Mac | Linux, on this Mac | on",
"---",
"aws | AWS · us-west-2 | t4g.medium, about $0.04/hour | on",
"modal | Modal · cua-byoc | 2 CPU, 4 GiB, about $0.10/hour | on *"
@@ -959,7 +959,7 @@
"placement": "local",
"placementError": null,
"placements": [
- "local | This Mac | Container on this Mac (gVisor when installed) | on *",
+ "local | This Mac | Linux, on this Mac | on *",
"---",
"aws | AWS · us-west-2 | t4g.medium, about $0.04/hour | on",
"modal | Modal · cua-byoc | 2 CPU, 4 GiB, about $0.10/hour | on"
@@ -968,18 +968,18 @@
"resourceFacts": [
"Kind: Container",
"Architecture: ARM",
- "Disk: 2.9 GB–6.9 GB initially; grows with use"
+ "Disk: 2.9–6.9 GB initially; grows with use"
],
"step": 2,
"summary": [
"System: Ubuntu 24.04",
"Image: ghcr.io/trycua/linux:24.04",
- "Runs on: This Mac",
+ "Runs on: Linux, on this Mac",
"Kind: Container",
"Architecture: ARM",
"Runtime: Container on this Mac (gVisor when installed)",
"Resources: 2 cores, 4 GB memory",
- "Disk: 2.9 GB–6.9 GB initially; grows with use",
+ "Disk: 2.9–6.9 GB initially; grows with use",
"Name: space-000000002a",
"When ready: Open the desktop"
],
diff --git a/libs/cua/crates/cua-spaces-app-core/src/dispatch.rs b/libs/cua/crates/cua-spaces-app-core/src/dispatch.rs
index 6295a9017f..0bae996d04 100644
--- a/libs/cua/crates/cua-spaces-app-core/src/dispatch.rs
+++ b/libs/cua/crates/cua-spaces-app-core/src/dispatch.rs
@@ -65,6 +65,7 @@ pub const METHODS: &[&str] = &[
"stream.pipReduce",
"stream.pipClick",
"window.chrome",
+ "window.emptyLinuxDetail",
"window.menuBar",
"window.menu",
"spaces.openableCount",
@@ -484,6 +485,9 @@ pub fn call_value(method: &str, args: Value) -> Result<Value, CoreError> {
&a.get::<Option<window::ChromeInput>>("input")?
.unwrap_or_default(),
)),
+ "window.emptyLinuxDetail" => {
+ out(window::empty_linux_detail_on(&a.get::<String>("hostArch")?))
+ }
"window.menu" => out(window::menu(&a.get::<window::MenuInput>("input")?)),
"spaces.openableCount" => out(spaces::openable_count(&a.get::<Vec<Space>>("spaces")?)),
"spaces.onCount" => out(spaces::on_count(&a.get::<Vec<Space>>("spaces")?)),
diff --git a/libs/cua/crates/cua-spaces-app-core/src/spaces/creating.rs b/libs/cua/crates/cua-spaces-app-core/src/spaces/creating.rs
index d8b2776caa..f3b0c90be2 100644
--- a/libs/cua/crates/cua-spaces-app-core/src/spaces/creating.rs
+++ b/libs/cua/crates/cua-spaces-app-core/src/spaces/creating.rs
@@ -532,6 +532,61 @@ pub fn transfer_text(
done: Option<u64>,
total: Option<u64>,
per_second: Option<f64>,
+) -> Option<String> {
+ transfer_text_with(done, total, per_second, Later::default())
+}
+
+/// What still has to happen after the download [`transfer_text_with`] shows,
+/// so its time left covers the whole create and not only the bytes in
+/// flight (the Linux runtime is followed by the image's download, and every
+/// download by unpacking and starting the Space).
+#[derive(Debug, Clone, Copy, Default, PartialEq)]
+pub struct Later {
+ /// Bytes still to download after this transfer.
+ pub bytes: u64,
+ /// Seconds of work that move no bytes after the downloads.
+ pub secs: f64,
+ /// The pace to assume until a rate is measured (a size and pace we
+ /// have measured, as for Linux); none promises no time before a rate.
+ pub pace: Option<f64>,
+}
+
+/// [`Later`] for `p`: the image's download while the runtime is being set
+/// up, then the measured start time ([`crate::wizard::CACHED_START_SECS`]),
+/// plus the runtime's own start while it is being set up.
+pub fn later_for(p: &PendingCreate) -> Later {
+ use crate::wizard::{CACHED_START_SECS, find_image, platform_size};
+ let runtime = setting_up_runtime(p);
+ let bytes = if runtime && p.os == SpaceOs::Linux {
+ p.image
+ .as_deref()
+ .and_then(find_image)
+ .and_then(|i| platform_size(&i, p.arch.as_deref()).map(|s| s.download))
+ .unwrap_or(0)
+ } else {
+ 0
+ };
+ // The managed runtime boots its VM before the image can be pulled.
+ let boot = if runtime { RUNTIME_BOOT_SECS } else { 0.0 };
+ Later {
+ bytes,
+ secs: CACHED_START_SECS + boot,
+ pace: (p.os == SpaceOs::Linux).then_some(crate::wizard::FIRST_RUN_BYTES_PER_SEC),
+ }
+}
+
+/// Seconds the built-in Linux runtime's VM takes to boot after its download
+/// (part of the measured 25 Oct 2026 first run, CUA-2281).
+const RUNTIME_BOOT_SECS: f64 = 20.0;
+
+/// [`transfer_text`] with the work after the transfer counted in the time
+/// left. Without a measured rate the first-run pace is used, so a time
+/// left is always shown for a known size and is never short.
+pub fn transfer_text_with(
+ done: Option<u64>,
+ total: Option<u64>,
+ per_second: Option<f64>,
+ later: Later,
) -> Option<String> {
let done = done?;
let total = total.unwrap_or(0);
@@ -569,11 +624,11 @@ pub fn transfer_text(
let u = unit(r as u64);
out.push_str(&format!(" \u{b7} {} {}/s", scaled(r as u64, u, 10.0), u.1));
}
- if let (Some(r), true) = (rate, total > 0) {
- out.push_str(&format!(
- " \u{b7} {}",
- time_left(total.saturating_sub(done) as f64 / r)
- ));
+ // Without a rate nothing is promised, unless a measured pace stands in.
+ let pace = rate.or(later.pace);
+ if let (Some(r), true) = (pace, total > 0) {
+ let secs = (total.saturating_sub(done).saturating_add(later.bytes)) as f64 / r + later.secs;
+ out.push_str(&format!(" \u{b7} {}", time_left(secs)));
}
Some(out)
}
@@ -1762,7 +1817,14 @@ pub fn pending_space(p: &PendingCreate) -> Space {
error: p.error.clone(),
credit_url: p.credit_url.clone(),
transfer: (!failed && !p.cancelling && (p.phase == "pulling" || setting_up_runtime(p)))
- .then(|| transfer_text(p.bytes_done, p.bytes_total, p.bytes_per_second))
+ .then(|| {
+ transfer_text_with(
+ p.bytes_done,
+ p.bytes_total,
+ p.bytes_per_second,
+ later_for(p),
+ )
+ })
.flatten(),
cancellable: !failed && !p.cancelling && p.space_id.is_none(),
cancelling: p.cancelling,
@@ -1849,6 +1911,46 @@ pub fn compose(registry: &[Space], state: &CreatesState) -> Vec<Space> {
mod tests {
use super::*;
+ #[test]
+ fn time_left_counts_the_downloads_and_starts_after_this_one() {
+ let mb = 1u64 << 20;
+ // 456 MB of runtime nearly done, at 20 MB/s: the bytes alone say
+ // seconds; the image still to come and the starts say minutes.
+ let alone = transfer_text(Some(440 * mb), Some(456 * mb), Some(20.0 * mb as f64)).unwrap();
+ assert!(alone.ends_with("less than a minute"), "{alone}");
+ let later = Later {
+ bytes: 1100 * mb,
+ secs: 26.0,
+ pace: None,
+ };
+ let whole = transfer_text_with(
+ Some(440 * mb),
+ Some(456 * mb),
+ Some(20.0 * mb as f64),
+ later,
+ )
+ .unwrap();
+ assert!(whole.ends_with("about 1 min"), "{whole}");
+ // No rate yet: the first-run pace stands in, never a bare "less than a minute".
+ let blind = transfer_text_with(
+ Some(0),
+ Some(1100 * mb),
+ None,
+ Later {
+ bytes: 0,
+ secs: 26.0,
+ pace: Some(crate::wizard::FIRST_RUN_BYTES_PER_SEC),
+ },
+ )
+ .unwrap();
+ assert!(blind.ends_with("about 3 min"), "{blind}");
+ // A stall message promises no time.
+ assert_eq!(
+ transfer_text(Some(mb), Some(10 * mb), None).unwrap(),
+ "1.0 of 10.0 MB"
+ );
+ }
+
#[test]
fn preflight_issue_reads_the_daemons_report() {
let report = r#"{"preflight":{
diff --git a/libs/cua/crates/cua-spaces-app-core/src/window.rs b/libs/cua/crates/cua-spaces-app-core/src/window.rs
index 3e0a3aeb8e..981ccfcab7 100644
--- a/libs/cua/crates/cua-spaces-app-core/src/window.rs
+++ b/libs/cua/crates/cua-spaces-app-core/src/window.rs
@@ -89,8 +89,7 @@ pub fn chrome(input: &ChromeInput) -> MainChrome {
settings_shortcut: "\u{2318},".into(),
empty_title: "No Spaces yet".into(),
empty_action: "Linux".into(),
- // Measured (#4817); catalog sizes omit the runtime and what a Space writes.
- empty_linux_detail: "About 1 minute \u{b7} 3.2\u{2013}7.1 GB of disk".into(),
+ empty_linux_detail: empty_linux_detail(),
empty_detail: "Choose a system for your first Space.".into(),
empty_macos_action: "macOS".into(),
empty_macos_detail: empty_macos_detail(),
@@ -98,6 +97,43 @@ pub fn chrome(input: &ChromeInput) -> MainChrome {
}
}
+/// The Linux card's line, from the catalog and the same footprint the
+/// wizard's Disk row shows (so the two agree), and the measured first-run
+/// pace: "About 3 minutes · 3.3–7.3 GB of disk".
+fn empty_linux_detail() -> String {
+ // The same words on every host (the goldens are shared by every shell and
+ // the wasm core cannot tell its CPU): Apple silicon's figures, which
+ // the page replaces with the host's own ([`empty_linux_detail_on`]).
+ empty_linux_detail_on("arm64")
+}
+
+/// [`empty_linux_detail`] for a host of `cpu` (`arm64`, `amd64`): the web
+/// core runs as wasm and cannot tell, so the page passes the host's.
+pub fn empty_linux_detail_on(cpu: &str) -> String {
+ use crate::wizard::{
+ LINUX_RUNTIME_DOWNLOAD_BYTES, container_footprint, duration_text, first_run_seconds,
+ picker_images, platform_size, size_range_text,
+ };
+ let images = picker_images();
+ let image = images
+ .iter()
+ .find(|i| {
+ i.os == crate::SpaceOs::Linux && i.local == Some(crate::wizard::LocalEngine::Container)
+ })
+ .expect("a Linux container image");
+ let arch = crate::run_arch(&image.arch, true, Some(cpu));
+ let row = platform_size(image, arch.as_deref()).expect("a Linux download size");
+ let (low, high) = container_footprint(row, LINUX_RUNTIME_DOWNLOAD_BYTES);
+ format!(
+ "{} \u{b7} {} of disk",
+ duration_text(first_run_seconds(
+ row.download,
+ LINUX_RUNTIME_DOWNLOAD_BYTES
+ )),
+ size_range_text(low, high)
+ )
+}
+
fn empty_macos_detail() -> String {
use crate::wizard::{picker_images, platform_size, size_text};
let images = picker_images();
@@ -279,6 +315,48 @@ pub fn menu(input: &MenuInput) -> Vec<MenuItem> {
mod tests {
use super::*;
+ #[test]
+ fn the_linux_card_follows_the_hosts_architecture() {
+ assert_eq!(
+ empty_linux_detail_on("arm64"),
+ "About 3 minutes \u{b7} 3.3\u{2013}7.3 GB of disk"
+ );
+ assert_ne!(
+ empty_linux_detail_on("amd64"),
+ empty_linux_detail_on("arm64")
+ );
+ }
+
+ #[test]
+ fn the_linux_card_reads_the_wizards_footprint_and_the_measured_first_run() {
+ use crate::wizard::{
+ LINUX_RUNTIME_DOWNLOAD_BYTES, container_footprint, find_image, platform_size,
+ size_range_text,
+ };
+ let c = chrome(&ChromeInput {
+ identity: None,
+ cloud_configured: false,
+ can_sign_in: false,
+ experiments: None,
+ });
+ let image = find_image("ghcr.io/trycua/linux:24.04").unwrap();
+ let arch = crate::run_arch(&image.arch, true, Some("arm64"));
+ let row = platform_size(&image, arch.as_deref()).unwrap();
+ let (low, high) = container_footprint(row, LINUX_RUNTIME_DOWNLOAD_BYTES);
+ let disk = format!("{} of disk", size_range_text(low, high));
+ assert!(
+ c.empty_linux_detail.ends_with(&disk),
+ "{}",
+ c.empty_linux_detail
+ );
+ // About 3 minutes on the measured Mac mini, never the old "About 1 minute".
+ assert!(
+ c.empty_linux_detail.starts_with("About 3 minutes"),
+ "{}",
+ c.empty_linux_detail
+ );
+ }
+
#[test]
fn the_account_line_prefers_the_identity() {
let c = chrome(&ChromeInput {
diff --git a/libs/cua/crates/cua-spaces-app-core/src/wizard.rs b/libs/cua/crates/cua-spaces-app-core/src/wizard.rs
index c3abab5eaa..0d9995a210 100644
--- a/libs/cua/crates/cua-spaces-app-core/src/wizard.rs
+++ b/libs/cua/crates/cua-spaces-app-core/src/wizard.rs
@@ -44,16 +44,30 @@ impl LocalEngine {
/// Tile description.
pub fn label(&self) -> String {
match self {
- LocalEngine::Container => "Container on this Mac (gVisor when installed)".into(),
+ LocalEngine::Container => "Linux, on this Mac".into(),
LocalEngine::Qemu => "QEMU virtual machine on this Mac".into(),
LocalEngine::Lume => "Lume virtual machine (Apple silicon)".into(),
LocalEngine::External(n) => format!("{} on this Mac", external_runtime_label(n)),
}
}
- /// [`Self::label`] in a shell on `os` ("Container on this PC ...").
+ /// [`Self::label`] in a shell on `os` ("Linux, on this PC").
pub fn label_on(&self, os: SpaceOs) -> String {
- let label = self.label();
+ Self::on(self.label(), os)
+ }
+
+ /// The engine as a developer names it, for the Summary's Advanced rows
+ /// (the plain [`Self::label`] everywhere else).
+ pub fn technical_label_on(&self, os: SpaceOs) -> String {
+ match self {
+ LocalEngine::Container => {
+ Self::on("Container on this Mac (gVisor when installed)".into(), os)
+ }
+ _ => self.label_on(os),
+ }
+ }
+
+ fn on(label: String, os: SpaceOs) -> String {
if os == SpaceOs::Macos {
label
} else {
@@ -2919,6 +2933,16 @@ pub fn size_text(bytes: u64) -> String {
}
}
+/// `3.3–7.3 GB`, `900 MB–2.1 GB`: a range, its unit said once when both ends
+/// share it.
+pub fn size_range_text(low: u64, high: u64) -> String {
+ let (a, b) = (size_text(low), size_text(high));
+ match (a.rsplit_once(' '), b.rsplit_once(' ')) {
+ (Some((n, ua)), Some((_, ub))) if ua == ub => format!("{n}\u{2013}{b}"),
+ _ => format!("{a}\u{2013}{b}"),
+ }
+}
+
/// `ARM`, `x64` (an OCI or Rust architecture name; others as they are).
pub fn arch_label(arch: &str) -> String {
crate::model::arch_label(arch).unwrap_or(arch).to_string()
@@ -2936,6 +2960,58 @@ fn run_arch(image: &SandboxImage, placement: Location, host: Option<&str>) -> Op
crate::model::run_arch(&image.arch, placement == Location::Local, host)
}
+/// A container Space's disk range on this machine, bytes: what it takes at
+/// first (the unpacked image plus the one-time Linux runtime download) up to
+/// what it can take as it fills. The one place this is worked out: the
+/// wizard's Disk row and the empty home's Linux card both read it.
+pub fn container_footprint(s: &PlatformSize, runtime_download: u64) -> (u64, u64) {
+ let low = s.unpacked.saturating_add(runtime_download);
+ let high = low.saturating_add(s.disk).saturating_add(s.download);
+ (low, high)
+}
+
+/// The one-time Linux runtime download the first Linux Space needs, bytes
+/// (the managed runtime image; the wizard reads the live figure from the
+/// storage probe, this is the figure a fresh Mac gets).
+pub const LINUX_RUNTIME_DOWNLOAD_BYTES: u64 = 477_884_184;
+
+/// What the first Linux Space on a fresh Mac takes, measured on a Mac mini
+/// on 25 Oct 2026 (CUA-2281): about 180 s for the 456 MB runtime plus the
+/// 1.1 GB image (download, unpack, runtime start), so bytes per second over
+/// the whole first create.
+pub const FIRST_RUN_BYTES_PER_SEC: f64 = 9_100_000.0;
+
+/// Seconds a Linux Space takes to start once its image is on the Mac
+/// (container create, start, cua-spacesd: 1 + 0.3 + 0.2 + 3.5 + 0.1 s
+/// measured through the SDK, rounded up).
+pub const CACHED_START_SECS: f64 = 6.0;
+
+/// Seconds the first Linux Space takes: the downloads at the measured first
+/// run's pace.
+pub fn first_run_seconds(download: u64, runtime_download: u64) -> f64 {
+ (download.saturating_add(runtime_download)) as f64 / FIRST_RUN_BYTES_PER_SEC + CACHED_START_SECS
+}
+
+/// "About 3 minutes", "About 1 minute", "A few seconds": a duration the way
+/// a person would say it, rounded to the minute.
+pub fn duration_text(secs: f64) -> String {
+ if !secs.is_finite() || secs < 0.0 {
+ return String::new();
+ }
+ if secs < 20.0 {
+ return "A few seconds".into();
+ }
+ if secs < 50.0 {
+ return "Under a minute".into();
+ }
+ let mins = (secs / 60.0).round().max(1.0) as u64;
+ match mins {
+ 1 => "About 1 minute".into(),
+ m if m < 60 => format!("About {m} minutes"),
+ m => format!("About {} h {} min", m / 60, m % 60),
+ }
+}
+
/// The image's sizes on `arch` (else its first platform).
pub(crate) fn platform_size<'a>(
image: &'a SandboxImage,
@@ -3079,13 +3155,9 @@ fn disk_view(state: &WizardState, image: &SandboxImage, env: &WizardEnv, os: Spa
});
if let Some(s) = size {
if bounds.is_none() {
- let initial = s.unpacked.saturating_add(runtime_download);
let footprint = if image.local == Some(LocalEngine::Container) {
- format!(
- "{}–{} initially; grows with use",
- size_text(initial),
- size_text(initial.saturating_add(s.disk).saturating_add(s.download))
- )
+ let (low, high) = container_footprint(s, runtime_download);
+ format!("{} initially; grows with use", size_range_text(low, high))
} else {
size_text(s.disk)
};
@@ -3514,7 +3586,7 @@ pub fn view_on(state: &WizardState, env: &WizardEnv, os: SpaceOs) -> WizardView
Location::Local => match &image.local {
// A provider is its own engine: "macOS VMs on this Mac".
Some(l @ LocalEngine::External(_)) => l.label_on(os),
- Some(l) if runtime == Runtime::Auto => l.label_on(os),
+ Some(l) if runtime == Runtime::Auto => l.technical_label_on(os),
Some(_) => runtime_word(&runtime, image.variant, os),
None => format!("Not available on {}", os.this_machine_lower()),
},
@@ -3573,7 +3645,11 @@ pub fn view_on(state: &WizardState, env: &WizardEnv, os: SpaceOs) -> WizardView
value: match (cloud.filter(|_| yours), host) {
(Some(c), _) => c.label.clone(),
(None, Some(h)) => h.name.clone(),
- _ => placement.label_on(os).into(),
+ _ => match &image.local {
+ // "Linux, on this Mac": the plain words, not the engine's.
+ Some(l @ LocalEngine::Container) if local => l.label_on(os),
+ _ => placement.label_on(os).into(),
+ },
},
copy: None,
help: None,
@@ -4166,6 +4242,23 @@ mod tests {
);
}
+ #[test]
+ fn plain_words_first_and_the_engine_as_a_developer_names_it() {
+ assert_eq!(LocalEngine::Container.label(), "Linux, on this Mac");
+ assert_eq!(
+ LocalEngine::Container.label_on(SpaceOs::Windows),
+ "Linux, on this PC"
+ );
+ assert_eq!(
+ LocalEngine::Container.technical_label_on(SpaceOs::Macos),
+ "Container on this Mac (gVisor when installed)"
+ );
+ assert_eq!(duration_text(190.0), "About 3 minutes");
+ assert_eq!(duration_text(200.0), "About 3 minutes");
+ assert_eq!(duration_text(30.0), "Under a minute");
+ assert_eq!(duration_text(100.0), "About 2 minutes");
+ }
+
fn on(image_ref: &str, e: &WizardEnv) -> WizardState {
let s = reduce(
&initial(e),
@@ -4224,9 +4317,8 @@ mod tests {
assert_eq!(
v.resource_facts[2].value,
format!(
- "{}–{} initially; grows with use (download {})",
- size_text(p.unpacked),
- size_text(p.unpacked + p.disk + p.download),
+ "{} initially; grows with use (download {})",
+ size_range_text(p.unpacked, p.unpacked + p.disk + p.download),
size_text(p.download)
)
);
@@ -4252,9 +4344,14 @@ mod tests {
&& f.value
.contains("includes 455 MB one-time Linux runtime download")
}));
- assert!(v.summary.iter().any(
- |f| f.label == "Disk" && f.value.starts_with(&size_text(p.unpacked + (455 << 20)))
- ));
+ assert!(v.summary.iter().any(|f| {
+ f.label == "Disk"
+ && f.value.starts_with(
+ size_text(p.unpacked + (455 << 20))
+ .trim_end_matches(" GB")
+ .trim_end_matches(" MB"),
+ )
+ }));
e.storage.as_mut().unwrap().linux_runtime_download_bytes = 0;
assert!(
!view(&s, &e)
@@ -4317,9 +4414,8 @@ mod tests {
(
"Disk".into(),
format!(
- "{}–{} initially; grows with use (download {})",
- size_text(p.unpacked),
- size_text(p.unpacked + p.disk + p.download),
+ "{} initially; grows with use (download {})",
+ size_range_text(p.unpacked, p.unpacked + p.disk + p.download),
size_text(p.download)
)
),
@@ -4336,9 +4432,8 @@ mod tests {
assert_eq!(
v.resource_facts[2].value,
format!(
- "{}–{} initially; grows with use",
- size_text(p.unpacked),
- size_text(p.unpacked + p.disk + p.download)
+ "{} initially; grows with use",
+ size_range_text(p.unpacked, p.unpacked + p.disk + p.download)
)
);
}