From 06fcc500d545e2a5c3c4e9d3b24951279f33adf4 Mon Sep 17 00:00:00 2001 From: "Danilo M." Date: Mon, 14 Sep 2026 12:19:45 +0200 Subject: docs: correct the plan's no-arg ipc open and the head pipe Quickshell 0.3.1 IPC requires every declared argument, so the plan's `ipc call drawer open` with no page fails; the page-less grid entry is the zero-argument `toggle`. Also records that `... | head` races timeout and kills the shell early, so verification uses a file redirect. --- docs/superpowers/plans/2026-09-14-desktop-shell.md | 26 +++++++++++++++++----- 1 file changed, 20 insertions(+), 6 deletions(-) (limited to 'docs/superpowers/plans') diff --git a/docs/superpowers/plans/2026-09-14-desktop-shell.md b/docs/superpowers/plans/2026-09-14-desktop-shell.md index d067b15..3476db6 100644 --- a/docs/superpowers/plans/2026-09-14-desktop-shell.md +++ b/docs/superpowers/plans/2026-09-14-desktop-shell.md @@ -34,6 +34,16 @@ Verification in this plan is therefore: start the shell in the foreground with a timeout, read what it printed, and kill by exact name. Anything visual is for the user to look at, not for a screenshot. +**Erratum (post-Task-4).** Two corrections found during execution, applying to +every verification block below: + +- The `... 2>&1 | head -20` form races `timeout` and kills the shell early. + Use a file redirect instead: `timeout N qs -p desktop > /tmp/opencode/x.log + 2>&1 &` then `sleep`, probe, `wait`, then read the log. +- Quickshell 0.3.1 IPC requires every declared argument present, so + `ipc call drawer open` with no page name fails. The page-less grid entry is + the zero-argument `ipc call drawer toggle`; `open` always takes a page name. + ## File structure ``` @@ -715,12 +725,16 @@ ShellRoot { } // The waybar launcher and the deep-link keybinds all reach this: - // qs -p ipc call drawer open -> the grid - // qs -p ipc call drawer open mail -> the mail page + // qs -p ipc call drawer toggle -> the grid + // qs -p ipc call drawer open mail -> the mail page + // Quickshell 0.3.1 IPC requires every declared argument to be present, + // and a parameter with a JS default registers as QVariant, which IPC + // rejects. So the page name cannot be optional: `open` always takes a + // page, and the page-less grid is `toggle`. IpcHandler { target: "drawer" function open(page: string) { drawer.show(page); } - function toggle(page: string) { drawer.toggle(page); } + function toggle() { drawer.toggle(""); } function close() { drawer.close(); } } } @@ -731,7 +745,7 @@ ShellRoot { ```bash timeout 8 qs -p desktop 2>&1 | head -20 & sleep 3 -qs -p desktop ipc call drawer open +qs -p desktop ipc call drawer toggle sleep 1 qs -p desktop ipc call drawer close wait @@ -836,7 +850,7 @@ and replace the `Drawer` block with: ```bash timeout 10 qs -p desktop 2>&1 | head -20 & sleep 3 -qs -p desktop ipc call drawer open +qs -p desktop ipc call drawer toggle sleep 5 wait pgrep -cx qs @@ -2532,7 +2546,7 @@ Reached from a launcher at the left end of waybar. qs -p ./desktop - qs -p ./desktop ipc call drawer open # the grid + qs -p ./desktop ipc call drawer toggle # the grid qs -p ./desktop ipc call drawer open mail # straight to a page ## The modules -- cgit v1.2.3