fix(keymap): prevent Niri and Hyprland CPU-budget failures (1.3.4) (#135)

* fix(keymap): reduce Niri parser CPU usage

* test(keymap): cover Niri parser scan budget

* fix(keymap): keep Hyprland refreshes within CPU budget

* chore(keymap): bump release to 1.3.4
This commit is contained in:
blacku
2026-07-28 21:11:34 -04:00
committed by GitHub
parent c04fe989e4
commit 9c60991b0d
9 changed files with 449 additions and 102 deletions
+7 -4
View File
@@ -59,10 +59,13 @@ assert all(";" not in entry["template"] and "{" not in re.sub(r"\{\{[^}]+\}\}",
assert all("#" not in entry["template"]
for entry in entries if entry["source"] == "mangowc")
# The retained UI deliberately renders only a small result window and removes
# callbacks that are no longer part of the current render.
# The retained UI deliberately renders only a small result window and passes
# closures directly instead of registering callback names in the script global
# environment. Keep this assertion aligned with the plugin API 9 callback form.
assert "local visibleCount = math.min(#matches, 6)" in panel
assert "finishDynamicCallbackRender()" in panel
assert 'registerDynamicCallback(callbackName' in panel
assert "local selectedEntry = entry" in panel
assert "onClick = useCallback" in panel
assert "finishDynamicCallbackRender()" not in panel
assert "registerDynamicCallback(" not in panel
print(f"command library tests: ok ({len(entries)} entries: {dict(counts)})")