E6: a block that reads a SKILL.md is not a missing install

The first live codex-multiblock-live run passed its real check (the /learn
block found the install and printed the seeded learning) but the oracle
flagged a sed of the learn SKILL.md, whose prelude source quotes the
'gstack: no install found (tried $_r)' text. Only an emitted line that
starts with the message and names a real root counts now; free replay
negative added.
This commit is contained in:
garrytan committed 2026-10-04 19:23:45 +00:00
1 parent 1526182c2c
commit c74c3df073
2 files changed
+9 -1

No files matched your search

+5
View File
@@ -29,6 +29,11 @@ describe('multiblockProblems', () => {
expect(problems[0]).toStartWith('a block could not find the install');
});
test('a block that reads a SKILL.md quoting the prelude is not a missing install (live run 2026-10-04)', () => {
const read = command("sed -n '1,120p' \"$CODEX_HOME/skills/gstack-learn/SKILL.md\"", `---\nname: learn\n---\n\n\`\`\`bash\n${PRELUDE}\n\`\`\`\n`, 0);
expect(multiblockProblems(run(preamble, read, command(SHOW_RECENT, LISTING, 0)))).toEqual([]);
});
test('the pre-prelude symptom (an empty root, /bin/gstack-slug) fails', () => {
const problems = multiblockProblems(run(command('SLUG=$($GSTACK_ROOT/bin/gstack-slug --get SLUG)\n$GSTACK_ROOT/bin/gstack-learnings-search',
'bash: line 1: /bin/gstack-slug: No such file or directory\nbash: line 2: /bin/gstack-learnings-search: No such file or directory\n', 127)));
+4 -1
View File
@@ -35,7 +35,10 @@ export function multiblockProblems(rawLines: readonly string[], sentinel = MULTI
const commands = completedCommands(rawLines);
const problems: string[] = [];
for (const { command, output } of commands) {
if (output.includes('gstack: no install found')) problems.push(`a block could not find the install: ${output.trim().slice(0, 200)}`);
// The emitted line names the root it tried; the prelude's source text
// (a block that reads a SKILL.md) quotes it mid-line with `$_r`.
const missing = /^gstack: no install found \(tried (?!\$)[^\n]*/m.exec(output);
if (missing) problems.push(`a block could not find the install: ${missing[0].slice(0, 200)}`);
const unresolved = /\S*\/bin\/gstack-[\w-]+: (?:No such file or directory|command not found|not found)/.exec(output);
if (unresolved) problems.push(`a gstack helper path did not resolve: ${unresolved[0]} (in: ${command.slice(0, 120)})`);
}