From 6daf236b585dc47ad8ffe293cdefd5de8231c5d8 Mon Sep 17 00:00:00 2001 From: Agando Date: Thu, 29 Oct 2026 12:53:41 +0100 Subject: feat(newos4): register `test` / `[` so chains decide locally instead of asking a model (v4.6.135) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit `[ -f "/qt.txt" ] && echo exists` — the probe that closed the v4.6.132 batch — was not a shell test at all: both commands were unregistered, so the line fell through to the AI fallback and a model was asked whether a file exists. `_evalTest()` has implemented `-f -d -e -z -n ! = !=` for the if/while parser since the script runner was written; only the command was missing. * `test` and `[` registered in ShellModule. Success resolves silently; false rejects with a `silent` error so `&&`/`||` skip it — POSIX prints nothing on exit 1. * `[` requires the closing bracket (`[ : missing ']'`), and that message is NOT silent. * `test` already names the on-demand regression-suite runner ("test auto" / "test list" in help.html). A argv that does not look like a test expression (`-f`/`-d`/`-e`/`-z`/`-n`/`!`, or `a = b` / `a != b`) is delegated to the handler registered before us, so `test auto` still runs the suite and the two meanings cannot collide. * terminal.dispatchCommand() now honours `err.silent` — without it a top-level `test -f /nope` printed `Error in ShellModule.test:` (measured on v4.6.134, fixed in v4.6.135). * help.html documents the bracket form next to the existing `test` row. Three tags were minted minutes apart — v4.6.133 (commands), v4.6.134 (suite delegation), v4.6.135 (silent top-level) — each a real cache-bust for a fix that superseded the previous build; the net change is this commit. Verification node modules/test/test-shell-test-cmd.js -> 24/24 pass (RED against HEAD: "test command registered" fails, "m.commands.test is not a function") node modules/test/test-pipe-guard.js -> all seven flags true node modules/test/test-parse-args.js -> 28/28 · daily job -> node tests 22/22 pass newos4-maintain.py -> atlas 355 commands (was 354), modules-index 349, help 364/364 live v4.6.135, read from the terminal DOM: [ -f /qt.txt ] && echo F135 -> F135 test -f /nope || echo M135 -> M135 [ -d /nope ] && echo BAD || echo N134-> N134 (false branch skipped, nothing printed) test -> no output (suite not loaded; POSIX false) test -f /nope -> no output js "a b".length | wc -c -> 1 (v4.6.132 pipe fix still intact) The AI fallback is no longer reachable for a bracketed file test. --- course/atlas.json | 158 +++++++++++++++++++++++++++++++++++++++++++----------- 1 file changed, 128 insertions(+), 30 deletions(-) (limited to 'course/atlas.json') diff --git a/course/atlas.json b/course/atlas.json index 4eeeff4..341ddb3 100644 --- a/course/atlas.json +++ b/course/atlas.json @@ -1,6 +1,6 @@ { - "version": "2026-10-21T23:46:07Z", - "source_hash": "fdf2b4d2aaf3dbc0", + "version": "2026-10-29T11:53:19Z", + "source_hash": "9f5f08a8dd1b7f05", "commands": { "a2a-ack": { "module": "module-agent-registry", @@ -587,6 +587,15 @@ "builtin": false, "example": "contract-register" }, + "cost": { + "module": "module-billing", + "file": "modules/core/module-billing.js", + "tier": "core-bundle", + "category": "general", + "desc": "cost [on|off] — AI prices, today's free-message allowance and this session's spend", + "builtin": false, + "example": "cost" + }, "course": { "module": "course", "file": "modules/ext/course.js", @@ -938,6 +947,33 @@ "builtin": false, "example": "factory-reset-old" }, + "feedback": { + "module": "module-debug-supervisor", + "file": "modules/core/module-debug-supervisor.js", + "tier": "core-bundle", + "category": "general", + "desc": "feedback — Send feedback to the WebX11 maintenance agent", + "builtin": false, + "example": "feedback" + }, + "feedback-admin": { + "module": "module-debug-supervisor", + "file": "modules/core/module-debug-supervisor.js", + "tier": "core-bundle", + "category": "general", + "desc": "feedback-admin — command from module-debug-supervisor", + "builtin": false, + "example": "feedback-admin" + }, + "feedback-inbox": { + "module": "module-debug-supervisor", + "file": "modules/core/module-debug-supervisor.js", + "tier": "core-bundle", + "category": "general", + "desc": "feedback-inbox — Read replies from the maintenance agent (admin session)", + "builtin": false, + "example": "feedback-inbox" + }, "fetch": { "module": "module-fetcher", "file": "modules/core/module-fetcher.js", @@ -1118,6 +1154,15 @@ "builtin": false, "example": "gui-text" }, + "guides": { + "module": "module-fs", + "file": "modules/core/module-fs.js", + "tier": "core-bundle", + "category": "filesystem", + "desc": "Use trash for recursive dir removal too", + "builtin": false, + "example": "guides" + }, "gunzip": { "module": "cryptogzip", "file": "modules/ext/cryptogzip.js", @@ -1163,6 +1208,33 @@ "builtin": false, "example": "help" }, + "hermes": { + "module": "module-debug-supervisor", + "file": "modules/core/module-debug-supervisor.js", + "tier": "core-bundle", + "category": "general", + "desc": "hermes — command from module-debug-supervisor", + "builtin": false, + "example": "hermes" + }, + "hermes-poll": { + "module": "module-debug-supervisor", + "file": "modules/core/module-debug-supervisor.js", + "tier": "core-bundle", + "category": "general", + "desc": "hermes-poll — command from module-debug-supervisor", + "builtin": false, + "example": "hermes-poll" + }, + "hermes-reset": { + "module": "module-debug-supervisor", + "file": "modules/core/module-debug-supervisor.js", + "tier": "core-bundle", + "category": "general", + "desc": "hermes-reset — command from module-debug-supervisor", + "builtin": false, + "example": "hermes-reset" + }, "history": { "module": "terminal", "file": "modules/core/terminal.js", @@ -1942,7 +2014,7 @@ "file": "modules/core/module-predictor.js", "tier": "core-bundle", "category": "general", - "desc": "predictor-config — Tune: confidence-threshold, min-data-points", + "desc": "predictor-config — Tune: confidence-threshold, min-data-points, pair-ttl", "builtin": false, "example": "predictor-config" }, @@ -1951,7 +2023,7 @@ "file": "modules/core/module-predictor.js", "tier": "core-bundle", "category": "general", - "desc": "predictor-status — Model accuracy, data points, prediction count", + "desc": "predictor-status — Paired accuracy, pending predictions, data points", "builtin": false, "example": "predictor-status" }, @@ -2419,7 +2491,7 @@ "file": "modules/ext/skill-pack-core.js", "tier": "ext-auto", "category": "ai", - "desc": "skill-create \"\" [tags] — Create a new skill", + "desc": "skill-create [--tags=a,b] [--category=x] — Create a new skill", "builtin": false, "example": "skill-create" }, @@ -2621,6 +2693,15 @@ "builtin": false, "example": "tar" }, + "test": { + "module": "shell", + "file": "modules/ext/shell.js", + "tier": "critical-ext-bundle", + "category": "shell", + "desc": "32 automated tests: filesystem, busybox, shell, cryptogzip, skills, security, modules. Load manually with load-local then test", + "builtin": false, + "example": "test" + }, "test-net": { "module": "module-servermon", "file": "modules/core/module-servermon.js", @@ -2748,12 +2829,12 @@ "example": "uptime" }, "usage": { - "module": "terminal", - "file": "modules/core/terminal.js", + "module": "module-billing", + "file": "modules/core/module-billing.js", "tier": "core-bundle", - "category": "system", - "desc": "usage — command from terminal", - "builtin": true, + "category": "general", + "desc": "usage — same as cost", + "builtin": false, "example": "usage" }, "vaultmind-connect": { @@ -3166,7 +3247,7 @@ "js-run", "node" ], - "lines": 96 + "lines": 139 }, "course": { "file": "modules/ext/course.js", @@ -3232,7 +3313,7 @@ "files", "preview" ], - "lines": 1151 + "lines": 1278 }, "finder": { "file": "modules/ext/finder.js", @@ -3296,7 +3377,7 @@ "contract-list", "contract-register" ], - "lines": 474 + "lines": 506 }, "module-aiasm": { "file": "modules/core/module-aiasm.js", @@ -3350,7 +3431,16 @@ "vaultmind-status", "wallet-lookup" ], - "lines": 4678 + "lines": 4934 + }, + "module-billing": { + "file": "modules/core/module-billing.js", + "tier": "core-bundle", + "commands": [ + "cost", + "usage" + ], + "lines": 185 }, "module-chatstudio": { "file": "modules/core/module-chatstudio.js", @@ -3384,9 +3474,15 @@ "debug-stats", "debug-sync", "debug-sync-url", - "debug-trends" + "debug-trends", + "feedback", + "feedback-admin", + "feedback-inbox", + "hermes", + "hermes-poll", + "hermes-reset" ], - "lines": 890 + "lines": 1228 }, "module-fetcher": { "file": "modules/core/module-fetcher.js", @@ -3410,6 +3506,7 @@ "empty-trash", "find", "grep", + "guides", "head", "ls", "ls-trash", @@ -3439,7 +3536,7 @@ "vfs-size", "wc" ], - "lines": 823 + "lines": 982 }, "module-leases": { "file": "modules/core/module-leases.js", @@ -3466,7 +3563,7 @@ "memgraph-stats", "memgraph-status" ], - "lines": 663 + "lines": 703 }, "module-modmgr": { "file": "modules/core/module-modmgr.js", @@ -3553,7 +3650,7 @@ "orchestrator-wake", "pipeline" ], - "lines": 1442 + "lines": 1485 }, "module-predictor": { "file": "modules/core/module-predictor.js", @@ -3563,7 +3660,7 @@ "predictor-config", "predictor-status" ], - "lines": 282 + "lines": 509 }, "module-sandbox": { "file": "modules/core/module-sandbox.js", @@ -3656,7 +3753,7 @@ "uptime", "version" ], - "lines": 815 + "lines": 834 }, "module-world-model": { "file": "modules/core/module-world-model.js", @@ -3668,7 +3765,7 @@ "world-model-refresh", "world-model-summary" ], - "lines": 600 + "lines": 647 }, "secret-vault": { "file": "modules/core/secret-vault.js", @@ -3693,9 +3790,10 @@ "script", "set", "sh", + "test", "unset" ], - "lines": 627 + "lines": 956 }, "skill-pack-core": { "file": "modules/ext/skill-pack-core.js", @@ -3716,7 +3814,7 @@ "skill-view", "skill-webdav-sync" ], - "lines": 1150 + "lines": 1334 }, "theme": { "file": "modules/ext/theme.js", @@ -3770,7 +3868,7 @@ "webdav-rm", "webdav-status" ], - "lines": 2368 + "lines": 2450 }, "wpm": { "file": "modules/ext/wpm.js", @@ -3782,12 +3880,12 @@ } }, "coverage": { - "commands": 346, - "described": 346, - "modules": 47, + "commands": 355, + "described": 355, + "modules": 48, "tiers": { - "core-bundle": 258, - "critical-ext-bundle": 28, + "core-bundle": 266, + "critical-ext-bundle": 29, "ext-auto": 60, "ext-manual": 0 } -- cgit v1.2.3