Uh oh!
There was an error while loading. Please reload this page.
refactor(execute): reshape for IPC server lifecycle - #406
Conversation
Warning This pull request is not mergeable via GitHub because a downstack PR is open. Once all requirements are satisfied, merge this PR as a stack on Graphite.
This stack of pull requests is managed by Graphite. Learn more about stacking. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit:dd2800e233
ℹ️ 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".
| > = Box::pin(std::future::ready(Ok(recorder))); | ||
| Some(Tracking { | ||
| input_negative_globs: negatives, | ||
| ipc_envs: Vec::new(), |
There was a problem hiding this comment.
Populate IPC envs before spawning
When automatic tracking is enabled, this constructs a completed dummy recorder and injects no VP_RUN_IPC_NAME into the child environment (ipc_envs is empty). Any runner-aware child using the provided client (Client::from_envs(std::env::vars_os())) will conclude it is outside the runner, so calls such as disableCache, ignoreInput, ignoreOutput, or tracked env reads are never reported; the parent then updates the cache with incomplete reports, which can leave watch/dev tasks cached or archive outputs the tool explicitly tried to exclude. This path needs to bind vite_task_server::serve(...) and pass its env entries to spawn() before enabling cache updates for runner-aware reporting.
Useful? React with 👍 / 👎.
6b6728f to
69e90aaCompare07c0122 to
f256aaeCompare69e90aa to
887d8a1Compare887d8a1 to
cef2366Comparef256aae to
58b706eComparecef2366 to
d3bc701Comparea92c611 to
70fab43Compare3925257 to
f0aef36Compareb293a61 to
9abf3f6Compare90e6422 to
9975d4cCompare9abf3f6 to
514e25cCompareReshape `vite_task::session::execute` (and the supporting modules: `spawn`, `fingerprint`, `cache`, `tracked_accesses`, `event`, and the summary reporter) to accommodate a per-task IPC server. The server itself is a placeholder on this branch: instead of actually calling `vite_task_server::serve(...)`, we construct an empty `Recorder` whose driver future resolves immediately with no traffic, and bind a `StopAccepting::noop()`. The downstream plumbing — async-join of the child with the server, `Reports` flowing into post-run fingerprinting and into the cache update — is fully in place but sees only the empty `Reports`, so behaviour is byte-for-byte identical to today's runner. The follow-up wires up the real `serve(...)`, embeds the napi addon, and injects `VP_RUN_NODE_CLIENT_PATH` into the child. That PR's `serve(Recorder::new(env_map))` is the only call that changes from "future::ready(Ok(recorder))" to the real bind. Adds `StopAccepting::noop()` to `vite_task_server` for the same placeholder use case; it's a tiny helper that's also useful for tests that need a value of the type without running a server. Also folds in the unrelated-but-blocking output-config refactor (`output: Option<UserInputsConfig>` instead of `Option<Vec<UserOutputEntry>>`) — both sides now route through `ResolvedGlobConfig::from_user_config`. The 80-odd plan-snapshot updates are mechanical consequences of that type change. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
9975d4c to
7d95cc5Compare514e25c to
4c0ac3dComparewan9chi
commented
May 28, 2026
Superseded by restructured 2-PR stack:
|

Reshape
vite_task::session::execute(and the supporting modules:spawn,fingerprint,cache,tracked_accesses,event, and thesummary reporter) to accommodate a per-task IPC server. The server
itself is a placeholder on this branch: instead of actually calling
vite_task_server::serve(...), we construct an emptyRecorderwhose driver future resolves immediately with no traffic, and bind
a
StopAccepting::noop(). The downstream plumbing — async-join ofthe child with the server,
Reportsflowing into post-runfingerprinting and into the cache update — is fully in place but
sees only the empty
Reports, so behaviour is byte-for-byteidentical to today's runner.
The follow-up wires up the real
serve(...), embeds the napiaddon, and injects
VP_RUN_NODE_CLIENT_PATHinto the child. ThatPR's
serve(Recorder::new(env_map))is the only call that changesfrom "future::ready(Ok(recorder))" to the real bind.
Adds
StopAccepting::noop()tovite_task_serverfor the sameplaceholder use case; it's a tiny helper that's also useful for
tests that need a value of the type without running a server.
Also folds in the unrelated-but-blocking output-config refactor
(
output: Option<UserInputsConfig>instead ofOption<Vec<UserOutputEntry>>) — both sides now route throughResolvedGlobConfig::from_user_config. The 80-odd plan-snapshotupdates are mechanical consequences of that type change.
Co-Authored-By: Claude Opus 4.7 (1M context) noreply@anthropic.com