GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — feat(client): serve getEnv over runner IPC by wan9chi · Pull Request #446 · voidzero-dev/vite-task

Conversation

@wan9chi

@wan9chi wan9chi commented Jun 13, 2026 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Member

Motivation

The JS client exposes getEnv, but before this slice it still fell back to no-op behavior. Runner-aware tools need a real request/response path for single env reads before those reads can be used for cache tracking.

Scope

Add the GetEnv protocol frame, Rust client response handling, server-side resolution from the spawned task env map, and a real NAPI getEnv implementation. This PR intentionally does not add tracked env reads to cache fingerprints.

Verification

  • cargo test -p vite_task_server --test integration
  • UPDATE_SNAPSHOTS=1 cargo test -p vite_task_bin --test e2e_snapshots fetch_env_reads_declared_env -- --ignored
  • cargo test -p vite_task_bin --test e2e_snapshots fetch_env_reads_declared_env -- --ignored

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
This was referenced Jun 13, 2026
fix(cache): provide runner IPC for explicit-input tasks #430
Merged
feat(cache): honor runner ignored inputs #431
Merged
feat(ipc): runner ↔ tool IPC channel with disableCache #441
Merged
@wan9chi Graphite App

wan9chi commented Jun 13, 2026 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Member Author
  • feat(cache): honor runner ignored inputs #431 Graphite
  • test(e2e): verify real Vite env cache tracking #451 Graphite
  • feat(cache): fingerprint getEnvs match sets #450 Graphite
  • feat(client): serve getEnvs over runner IPC #449 Graphite
  • feat(cache): fingerprint tracked getEnv reads #448 Graphite
  • fix(plan): serve runner getEnv from unfiltered env context #447 Graphite
  • feat(client): serve getEnv over runner IPC #446 Graphite 👈 (View in Graphite)
  • fix(cache): provide runner IPC for explicit-input tasks #430 Graphite
  • feat(ipc): runner ↔ tool IPC channel with disableCache #441 Graphite
  • refactor(execute): single exit paths for pipe/wait and cache update #442 Graphite
  • main

This stack of pull requests is managed by Graphite. Learn more about stacking.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

This was referenced Jun 13, 2026
refactor(execute): single exit paths for pipe/wait and cache update #442
Merged
fix(plan): serve runner getEnv from unfiltered env context #447
Merged
feat(cache): fingerprint tracked getEnv reads #448
Merged
feat(client): serve getEnvs over runner IPC #449
Merged
feat(cache): fingerprint getEnvs match sets #450
Merged
test(e2e): verify real Vite env cache tracking #451
Merged
@wan9chi
wan9chi force-pushed the infra-get-env-ipc branch from 87459b6 to fc06b30 Compare June 13, 2026 11:11
@wan9chi
wan9chi force-pushed the infra-env-track branch from 7af1b0c to 93a665b Compare June 13, 2026 14:22
@wan9chi
wan9chi force-pushed the infra-get-env-ipc branch 2 times, most recently from 1174ec4 to e301d62 Compare June 13, 2026 14:27
@wan9chi
wan9chi force-pushed the infra-env-track branch from 93a665b to 675e0cb Compare June 13, 2026 14:27
@wan9chi
wan9chi changed the base branch from infra-env-track to graphite-base/446 June 13, 2026 14:35
@wan9chi
wan9chi force-pushed the infra-get-env-ipc branch from e301d62 to 9d3eeb1 Compare June 13, 2026 14:35
@wan9chi
wan9chi force-pushed the graphite-base/446 branch from 675e0cb to 1ae40ca Compare June 13, 2026 14:35
@graphite-app
graphite-app Bot changed the base branch from graphite-base/446 to main June 13, 2026 14:36
@wan9chi
wan9chi force-pushed the infra-get-env-ipc branch 2 times, most recently from 1d8eec4 to 01191f8 Compare June 13, 2026 15:58
@wan9chi
wan9chi marked this pull request as ready for review June 13, 2026 15:59
@wan9chi
wan9chi force-pushed the infra-get-env-ipc branch from 01191f8 to a20f693 Compare June 13, 2026 16:01
@wan9chi
feat(client): serve getEnv over runner IPC
ad9922d
Motivation:
The JS client already exposes getEnv, but before this change it always fell back to no-op behavior. Runner-aware tools need a real round-trip way to ask the runner for an env value before those reads can be used for cache tracking.

Scope:
Add the GetEnv request/response frame, response reading in the Rust client, server-side resolution from the spawned task env map, and a real NAPI getEnv implementation. This PR intentionally does not add tracked envs to cache fingerprints.

Verification:
- cargo test -p vite_task_server --test integration
- UPDATE_SNAPSHOTS=1 cargo test -p vite_task_bin --test e2e_snapshots fetch_env_reads_declared_env -- --ignored
- cargo test -p vite_task_bin --test e2e_snapshots fetch_env_reads_declared_env -- --ignored
chatgpt-codex-connector[bot]
chatgpt-codex-connector Bot reviewed Jun 13, 2026
View reviewed changes

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

There was a problem hiding this comment.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 01191f8ed1

ℹ️ 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".

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Comment thread crates/vite_task/src/session/execute/mod.rs
// TODO(env-track): A later PR in this stack replaces this child env
// map with the full planned env context so IPC can serve envs even
// when they were not declared in `env` or `untrackedEnv`.
&spawn_execution.spawn_command.all_envs,

@chatgpt-codex-connector chatgpt-codex-connector Bot Jun 13, 2026

Copy link
Copy Markdown

There was a problem hiding this comment.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Avoid serving untracked envs without cache-key tracking

When a cached task declares an output-affecting variable under untrackedEnv, SpawnCommand::all_envs still contains that value, so this handoff lets getEnv("FOO") return it even though this commit does not record env reads in Reports or add them to the cache fingerprint. A task can then cache output that depends on FOO and incorrectly hit after FOO changes; until tracked reads are implemented, serve only fingerprinted envs or force tracked getEnv reads to affect/disable caching.

Useful? React with 👍 / 👎.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Comment thread crates/vite_task_server/src/lib.rs
}

fn get_env(&mut self, name: &OsStr) -> Option<Arc<OsStr>> {
self.envs.get(name).cloned()

@chatgpt-codex-connector chatgpt-codex-connector Bot Jun 13, 2026

Copy link
Copy Markdown

There was a problem hiding this comment.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Match env names case-insensitively on Windows

On Windows, env names are case-insensitive, and the planner already matches env config case-insensitively while preserving the parent variable's original casing. If the spawned env contains Path but a tool calls getEnv("PATH") (or declares env: ["PATH"]), this exact FxHashMap lookup returns None even though the child process has that variable; use a case-insensitive lookup under cfg(windows) to match spawned-process semantics.

Useful? React with 👍 / 👎.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@wan9chi
wan9chi force-pushed the infra-get-env-ipc branch from a20f693 to ad9922d Compare June 13, 2026 16:03
@wan9chi Graphite App

wan9chi commented Jun 13, 2026 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Member Author

Merge activity

  • Jun 13, 4:08 PM UTC: A user started a stack merge that includes this pull request via Graphite.
  • Jun 13, 4:08 PM UTC: @wan9chi merged this pull request with Graphite.
All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@wan9chi
wan9chi merged commit e3747d1 into main Jun 13, 2026
20 checks passed

Uh oh!

There was an error while loading. Please reload this page.

@wan9chi
wan9chi deleted the infra-get-env-ipc branch June 13, 2026 16:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

@chatgpt-codex-connector chatgpt-codex-connector[bot] chatgpt-codex-connector[bot] left review comments

Uh oh!

There was an error while loading. Please reload this page.

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

Uh oh!

There was an error while loading. Please reload this page.

1 participant

@wan9chi
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.
You are visitor 01402775 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.