Repository navigation
Conversation
The qs ipc client prints Qt diagnostics on stdout; since Qt 6.12 the non-UTF-8 locale warning lands there ahead of the listPlugins JSON, so omarchy plugin list dies on a jq parse error and --json serves a poisoned payload. Skip to the JSON array, and fail with a clear message when no payload ever arrives instead of reporting an empty plugin list. Fixes omacom#15834
[Medium impact] The PR appears safe to merge, with the previous test finding fully addressed. Summary
Reviews (2) · Last reviewed commit: "Test the clean plugin list without the w..." · Reviewed by Greptile |
The clean-payload case swapped only the plugin data and kept the stub that prints the Qt locale warning, so it ran the warning case a second time and a change that broke output with no preamble would still have passed. Give that case a stub that prints the payload alone, and check --json as well as the table. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
Thanks for this, @AnPod. I reviewed it on an Omarchy worker (Qt 6.12.0, quickshell 0.3.2, session locale POSIX), and the bug is real: I pushed one test-only commit (6c81cc1). The "clean payload" case still used the stub that prints the warning, so it repeated the warning case, as Greptile pointed out. It now prints the payload alone and checks There is an older open fix for the same bug: #15128 runs the The second opinion was Codex Medium. It reviewed this branch and found no defect. Asked separately which of the two should land, it chose #15128 for the same reasons; it agreed with my reading rather than reaching it independently, since independence is not guaranteed. This now waits on the maintainer. |
|
Closing as superseded by the older #15128. |
Problem
Since Qt 6.12, the
qs ipcclient prints Qt's non-UTF-8 locale warning on stdout (nothing goes to stderr), so everyomarchy-shell shell listPluginscall in a non-UTF-8 session carries the warning lines ahead of the JSON payload.omarchy plugin listthen dies onjq: parse error: Invalid numeric literal at line 1, column 2, andomarchy plugin list --jsonserves the poisoned payload to every consumer (see #15834).Fix
bin/omarchy-plugin-listnow skips to the first line that starts the JSON array before using the payload, mirroring the consumer-side lesson from #6378 (fix the shipped consumer rather than wait for the producer's upstream). A call that never produces a payload now fails with a clear "omarchy-shell returned no plugin list" message instead of a jq parse error or a silently empty plugin list.The root cause lives in the
qs ipcclient (Quickshell), so the preamble itself is worth reporting upstream too; this keeps the shipped consumers working meanwhile.Test
New
test/shell.d/plugin-list-locale-warning-test.shstubsomarchy-shellto emit the exact Qt 6.12 warning preamble ahead of a plugin list and asserts:--jsonoutput starts with the payload, not the warningVerified it fails without the fix (jq parse error, exit 5) and passes with it.
Fixes #15834