Repository navigation
Conversation
Automated AI review
Outcome: Merged into current Cache version
|
|
Reviewed and run on a disposable Omarchy worker with Hyprland 0.56.2. The fix works, and I pushed three commits to your branch. Reproduction. With the zoom set to 2, picking What I pushed:
Tests on the worker: Second opinion: Codex Medium reviewed the branch over two rounds. It found the Waiting on: the maintainer. It is verified at 59e8ede, but not marked ready until the |
|
|
Pushed 8316867 for the two review findings. Reload between the lookup and the call. A reload starts Hyprland's Lua state over. Checked on 0.56.2: a value set through Tests that run the function. The dispatch stub now runs the dispatched expression in
The |
A bind given a plain Lua function, like Reset zoom, leaves no expression for the menu to replay, so picking it did nothing. The menu now records which bind the row is, looks that bind up again when it is picked, and calls the function through the registry ref Hyprland reports for it. A reload can hand that ref to another function between the lookup and the call. Each pick leaves a mark in the Lua state before the lookup and the call checks for it, so a reload in between is refused instead of running another function. The picked row is matched through the environment instead of awk -v, which reads a backslash in a description as an escape and then matches no row. The cache version moves to v19 so rows cached without a dispatcher are rebuilt.
15ee388 to
03cbacb
Compare
|
I've seen 03cbacb: one commit rebased onto This head has not been re-verified yet. Every item here gets a second opinion, and today's budget for those is used up, so Codex Medium did not run on this head. Without it, the classification at this head can't be confirmed by a second model, and the review stopped there. Nothing was run on a worker for 03cbacb, and the Waiting on: the maintainer, or a fresh pass once the second opinion is available again. |
…evidence as known_issue_not_reproduced (fixed by omacom#11851) (box) pocs/crs-260930-jvx8-c02.sh exits 1 (defect fixed) on this tree; evidence recaptured with --green-tripwire --accept-flip --revision <tree HEAD> on the Linux audit box. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
…tro-proof 1e43373) Mirror of omacom#11851 at head 03cbacb: the upstream change applied onto quattro-proof 1e43373, followed by the proof work for the review. This commit changes no file; it records the mirror at the branch tip, where the review pipeline reads it (Proof-* trailers). Proof-Change-Key: pr/11851 Proof-Upstream-Repo: github.com/omacom/omarchy Proof-Mirror-Of: refs/pull/11851/head Proof-Upstream-Head: 03cbacb Proof-Head-Ref: keybindings-menu-lua-function-binds Proof-Change-Base: 821ae58 Proof-Base-Ref: quattro Proof-Baseline: 1e43373 Proof-Baseline-Ref: quattro-proof
|
TL;DR: Stubbed picks on this head ( This adds a stubbed execution check to the current-head review. Hyprland and the picker were stubbed; it does not repeat the earlier head's Dispatch comparison, integration and existing tests
What a pick from the menu runs, per tree (stubbed)Real
In the same setup, Our audit's reproducer for this bugWe track this as KI-MENU-KEYBINDINGS-FUNC-BIND-NO-DISPATCH. Its reproducer, A description containing a comma still shifts the fields on both trees ( A test for the new-bind case: passes on this head, fails with
|
|
Status at
@omarchybot this head has had no worker run yet. Can it get a fresh pass? |
Super + Klists Lua function bindings, but selecting one did nothing. For example, a user who zooms in, searches forReset zoom, and presses Enter gets no reset or message; the script exits 1. Five of the 232 default bindings on Omarchy 4.0.2 are affected:Zoom in,Reset zoom, and the three universal clipboard actions. User-defined function binds have the same failure.The menu replays the Lua config to recover each action, but a plain Lua function leaves no expression to replay. Hyprland reports these binds as
__luawith a registry ref. When an expression is available from the source, the expression still wins. Otherwise, the menu records the bind's modifier mask, submap, key, keycode, and description. The record is stored base64-encoded, because later steps rewrite text in that field for display (key names forcode:NN, the Omarchy bin path).A config reload can assign the same registry ref to a different function. At dispatch time, the menu rereads
hyprctl bindsand requires exactly one__luabind to match the recorded identity. The menu calls the ref currently attached to that bind through the existinghl.dispatchpath, and refuses a blank or nonnumeric ref.A reload also starts Hyprland's Lua state over. Before the lookup, each pick writes a mark of its own into a table in the Lua registry, and the call checks for that mark. A reload between the lookup and the call removes the mark, so the call raises an error and nothing runs. Overlapping picks keep separate marks, and a pick removes its own mark whether it is called or refused.
The picked row is now matched through the environment instead of
awk -v, which reads a backslash in a description as an escape and then matches no row. This affected every bind kind. When two rows read the same and one of them is a function bind, the pick is refused, because the menu cannot tell which row was picked.The cache version moves from
v14tov19so cached rows with blank dispatcher fields are rebuilt. Open pull requests already usev15tov18.PR #11733 is a broader rewrite of the keybindings scan across 11 files. This PR keeps that work separate and fixes the current script.
Testing
bash test/shell.d/keybindings-menu-test.sh: all 33 passed (16 existing and 17 new). The stubbedhyprctl dispatchruns the dispatched expression inlua, so the tests assert which function was called.awk -vfor the picked row, the first of two identical rows dispatched, and a picked row that is not dispatched.bash test/shell.d/bin-style-test.sh: passed.git diff --check: passed.Reset zoomchangedzoom_factorfrom 1.5 to 1,Zoom inchanged it from 1 to 2, and two menus started together both exited 0. No mark was left in the Lua registry afterwards../test/shell: 279 of 290 test files passed. The 11 failures also fail on the unchanged base commit821ae589; four of them require anomarchy-pkgscheckout that is not present on this machine../test/cli: one check fails, "vscode generated theme references current theme file". It fails the same way on821ae589(test/cli vscode assert expects a symlink that 977e0fcd replaced with a real file #13131).Not included
hyprctl bindsrefuses that pick once. Nothing runs, and picking again works.{ ok = false }still makes the script exit 0, becausehyprctl dispatchprintsokfor it.parse_binding_records,static_bindings, and every test that reads rendered rows, so that belongs in a separate change.