Repository navigation
Conversation
|
Review the following changes in direct dependencies. Learn more about Socket for GitHub.
|
`vp run --json` prints every package and task in the workspace, with each task's `dependsOn` resolved to task IDs, as one JSON document, as docs/rfcs/task-graph-json.md specifies. Like `vp run` without a task, it loads every package's config, and a broken one fails the whole command. - The document types live in `vt::session::task_graph_json`. A test generates `crates/vt/schemas/task-graph.json` from them with schemars, which is only a dev-dependency. - `artifact!` embeds that schema, and each `--json` run copies it to `task-graph_<hash>.json` in the user's own `vp-schemas` folder in the system temp directory, unless it's already there. `$schema` points to that copy. - `--json` is exclusive, like `--last-details`. - `vtt pipe-stdout` lets an e2e step snapshot what a command prints when its stdout isn't a terminal. - The RFCs describe the temp-directory schema, and say that a `dependsOn` cycle doesn't stop the task graph from printing. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
wan9chi
force-pushed
the
claude/task-graph-json
branch
from
November 6, 2026 01:31
dda3eb3 to
1c6ac94
Compare
fspy benchmarklinuxmacoswindows |
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes using default effort and found 2 potential issues.
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit 1c6ac94. Configure here.
- fspy's seccomp handler compared syscall numbers with `as _`, which became ambiguous once `--all-features` (vt_str's new `schemars` feature) brought serde_json's `PartialEq<Value> for i32` into fspy's dependency graph. The cast now names `c_int`. - The schema test reads `CARGO_MANIFEST_DIR` at runtime: CI builds the Windows tests on Linux, so `env!` gave a Linux path. - The plan fixture no longer has a task with `cwd: ".."`: the internal `task_graph.md` dump keeps the `..` on Unix but not on Windows. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Motivation
Shell completion, editor task panels, CI scripts and coding agents need the workspace's tasks, and how they depend on each other, without parsing text or loading every
vite.config.*themselves (#320, voidzero-dev/vite-plus#2848, voidzero-dev/vite-plus#1182). The task graph RFC specifiesvp run --jsonfor this, and this PR implements it.Changes
vp run --jsonprints every package and every task in the workspace, with each task'sdependsOnresolved to task IDs. It's indented when stdout is a terminal and on one line otherwise. A one-element command array prints as a string.vp runwithout a task, it loads every package's config, now that configs load lazily (feat(task-graph): load a package's config only when a run reads its tasks #944). A broken config in any package fails the whole command: the error goes to stderr, and nothing goes to stdout. AdependsOncycle isn't an error.--jsonis exclusive, like--last-details.$schema: a test generatescrates/vt/schemas/task-graph.jsonfrom the document's Rust types with schemars, which is only a dev-dependency, using the types' doc comments as descriptions.artifact!embeds that file. Each--jsonrun copies it totask-graph_<hash>.jsonin the user's ownvp-schemasfolder in the system temp directory (fix: materialize artifacts in the user's own temp folder #947), unless it's already there, and$schemais that file'sfile://URL.vtt pipe-stdoutlets an e2e step snapshot what a command prints when its stdout isn't a terminal.$schemapoints to the temp-directory copy rather than to a file in the vite-plus package.dependsOnentries form a cycle.--jsonloads every config.Keeping output that a config prints while loading off stdout, which the RFC requires, is left for later. Only vite-plus's in-process
vite.config.*loader can print.🤖 Generated with Claude Code
Note
Low Risk
New read-only CLI path with extensive snapshot/e2e coverage; behavior changes are limited to additive
--jsonoutput and temp-dir schema writes, not task execution or caching.Overview
Adds
vp run --json, which loads every package config (same as listing tasks), runs nothing, and prints one JSON document with all workspace packages, tasks, and resolveddependsOntask IDs. Output is pretty-printed on a TTY and compact when stdout is piped;--jsonis mutually exclusive with other run modes (task name,-r, etc.).The payload includes
$schema,version,workspaceRoot, and stable task ID encoding (#/%escaped). A committedschemas/task-graph.jsonis generated from Rust document types via schemars and embedded at build time; each run materializes it under a per-user tempvp-schemasfolder and points$schemaat afile://URL (RFC/docs updated accordingly).Supporting work: new
task_graph_jsonsession module, publicpackage_graph()on the indexed graph, optional schemars onStr,vtt pipe-stdoutfor e2e snapshots of captured stdout, and a seccomp macro cast fix so adding serde_json/schemars does not break syscall-number comparisons.Reviewed by Cursor Bugbot for commit 19e4c82. Bugbot is set up for automated code reviews on this repo. Configure here.