Add structured automation outputs and bump to 0.1.35-rc.2#10
Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 73da14fd2a
ℹ️ 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 response = await requestSession(options.session, "tree.get"); | ||
| const action = command === "stats" ? "tree.stats" : "tree.get"; | ||
| const response = await requestSession(options.session, action, { | ||
| top: options.top ? Number(options.top) : undefined, |
There was a problem hiding this comment.
Respect explicit --top 0 in tree stats requests
The payload builder drops --top 0 because the truthy check treats 0 as absent, so rdt tree stats --top 0 sends top: undefined and the runtime falls back to the default (10) instead of honoring the caller’s explicit limit handling. This produces unexpectedly larger summaries and diverges from runtime-side clamping behavior.
Useful? React with 👍 / 👎.
| if (!details) { | ||
| return createRuntimeError( | ||
| "node-not-found", | ||
| `Node "${nodeId}" is not available in the current snapshot or commit context.`, |
There was a problem hiding this comment.
Preserve raw source.reveal null semantics for missing nodes
This now returns a runtime error whenever the node is missing, even when structured is not requested. Previously, raw source reveal returned null for missing nodes (node ? node.source : null), and the docs in this change describe unstructured mode as preserving legacy behavior; with this branch, stale or out-of-scope node IDs now hard-fail automation flows that previously treated missing source data as nullable.
Useful? React with 👍 / 👎.
Summary
package.jsonandpackage-lock.jsonto0.1.35-rc.2so npm trusted publishing continues to target thenextdist-tagrdt doctor,tree stats, structured search/source output, and click delivery controls)Validation
npm run buildnpm testMaintainer Notes
0.1.35prerelease line intentionally instead of minting a new stable tag while follow-up validation is still ongoing.session open --format jsonstdout report from round 2.