feat(examples): adopt semantic event route - #182
Conversation
Replace the demo's configured prebuilt PostToolUse hooks with one filesystem event route and replay checked-in Claude and Codex envelopes through the generated native wrappers.
|
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: da49cfc723
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| const snapshot = await createFileRuntimeKernel({ stateFile }).recordEdit({ | ||
| host: normalized.host, | ||
| idempotencyKey: canonical.idempotencyKey, | ||
| path: normalized.path, | ||
| sessionId: normalized.sessionId, | ||
| toolName: normalized.toolName, | ||
| }, { signal }); |
There was a problem hiding this comment.
Restore the launch probe on the packaged hook path
When eval:hosts -- --host claude runs a successful packaged hook, this route records state but never appends to AGENT_RUNTIME_HOOK_PROBE_FILE; the only writer remains src/hook/cli.ts, whose prebuilt hook declarations were removed from the package configuration. Consequently scripts/eval-hosts.mjs observes zero launches, classifies hook-dispatch and shared hook/MCP state as unavailable, and exits nonzero even when the route, edit, and MCP calls all succeed. Preserve the value-free probe on the new event-route execution path.
AGENTS.md reference: AGENTS.md:L10-L12
Useful? React with 👍 / 👎.
There was a problem hiding this comment.
Fixed in #196 (merged as 8c77ce6). The packaged event route now appends the same value-free probe line to AGENT_RUNTIME_HOOK_PROBE_FILE as the original hook CLI (shared writeEvalProbe in src/hook/eval-probe.ts; exitStatus: 0 on success, 1 on failure), so eval:hosts can observe packaged hook execution again. Covered by a route-unit test pinning the exact probe format.
…e example's semantic event route (#182) Both features merged while main CI was already red, so their outdated sibling tests were never caught: normalizeHooks now orders hooks by stable id, the rsc-agent-runtime example declares one tool/after event route instead of per-host prebuilt hooks, and the workbench therefore exposes the simulatable Hooks capability page.
… can go green (#197) * test: align hook expectations with sorted normalization (#180) and the example's semantic event route (#182) Both features merged while main CI was already red, so their outdated sibling tests were never caught: normalizeHooks now orders hooks by stable id, the rsc-agent-runtime example declares one tool/after event route instead of per-host prebuilt hooks, and the workbench therefore exposes the simulatable Hooks capability page. * fix(ci): keep route-unit proofs out of the example plain test pool * fix(ci): defer to the mainline Skill IR digest canonicalization (#191)
Summary
src/events/tool/after.tsxEvidence table additions
tool/aftersupport mappings landed in feat(events): publish host family capability states #173.Runtime coordination
@agent-bundle/runtimepackage changes.Test plan
pnpm eval:spotpnpm --filter @agent-bundle/rsc-agent-runtime-demo exec rstest run tests/host-artifacts.test.ts --config rstest.config.ts(5 passed)pnpm --filter @agent-bundle/rsc-agent-runtime-demo exec rstest run tests/docs-contract.test.ts --config rstest.config.ts(4 passed)pnpm --filter @agent-bundle/rsc-agent-runtime-demo typecheckpnpm lint