F1: settings.set refuses quoted, padded and control-character paths

Path settings get Kind::Path, checked by check_path in the engine: the one
validator for settings.set from agents, the CLI and the dialog. settings.list
marks them with path: true; the dialog uses that flag for Browse and shows
the engine's reason (userMessage drops the invalid-params prefix).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
danny 2026-11-02 19:02:08 +01:00
parent 750ecf5e51
commit 8a05f508c8
8 changed files with 150 additions and 51 deletions

View file

@ -361,13 +361,13 @@ describe("settings dialog", () => {
expect((input().element as HTMLInputElement).value).toBe("20");
});
it("shows the engine's error for a value it refuses", async () => {
it("shows the engine's error for a value it refuses, without the key the row already names", async () => {
const wrapper = await mountDialog();
await open(wrapper);
await useSettingsStore(pinia).set("editor.fontSize", 2);
await wrapper.find("[data-section=editor]").trigger("click");
expect(row(wrapper, "editor.fontSize").find("[data-test=settings-error]").text()).toBe(
"editor.fontSize: expected an integer from 8 to 48",
"expected an integer from 8 to 48",
);
});