Skip to content

feat(cache): fingerprint tracked getEnvs match sets#450

Open
wan9chi wants to merge 1 commit into
infra-get-envs-ipcfrom
infra-get-envs-fingerprint
Open

feat(cache): fingerprint tracked getEnvs match sets#450
wan9chi wants to merge 1 commit into
infra-get-envs-ipcfrom
infra-get-envs-fingerprint

Conversation

@wan9chi

@wan9chi wan9chi commented Jun 13, 2026

Copy link
Copy Markdown
Member

Motivation

Bulk env reads are only cache-safe if the cache remembers the entire matched env set. Without match-set fingerprinting, changing a matching env value, adding a new matching name, or removing one could replay stale output.

Scope

Make the getEnvs tracked option meaningful, record tracked match sets in IPC reports, store SHA-256 hashes for the matched env values in the post-run fingerprint, validate changed/added/removed matches during cache lookup, and render env-specific miss messages without exposing values. This follows the env hashing model from #455. This PR does not add the real Vite fixture.

Verification

  • cargo check -p vite_task
  • cargo test -p vite_task_server --test integration
  • cargo test -p vite_task_bin --test e2e_snapshots fetch_envs_tracks_glob_match_set -- --ignored

wan9chi commented Jun 13, 2026

Copy link
Copy Markdown
Member Author

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.
Learn more

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

@wan9chi wan9chi changed the base branch from infra-get-envs-ipc to graphite-base/450 June 13, 2026 11:11
@wan9chi wan9chi force-pushed the graphite-base/450 branch from 2f508b0 to e078bf2 Compare June 13, 2026 11:11
@wan9chi wan9chi force-pushed the infra-get-envs-fingerprint branch from 8bf068d to 2f128bc Compare June 13, 2026 11:11
@wan9chi wan9chi changed the base branch from graphite-base/450 to infra-get-envs-ipc June 13, 2026 11:11
@wan9chi wan9chi changed the base branch from infra-get-envs-ipc to graphite-base/450 June 13, 2026 14:22
@wan9chi wan9chi force-pushed the infra-get-envs-fingerprint branch from 2f128bc to 5a8cde0 Compare June 13, 2026 14:23
@wan9chi wan9chi force-pushed the graphite-base/450 branch from e078bf2 to 6e58a88 Compare June 13, 2026 14:23
@wan9chi wan9chi changed the base branch from graphite-base/450 to infra-get-envs-ipc June 13, 2026 14:23
@wan9chi wan9chi changed the base branch from infra-get-envs-ipc to graphite-base/450 June 13, 2026 14:26
@wan9chi wan9chi force-pushed the infra-get-envs-fingerprint branch from 5a8cde0 to 4990502 Compare June 13, 2026 14:27
@wan9chi wan9chi force-pushed the graphite-base/450 branch from 6e58a88 to 01ea610 Compare June 13, 2026 14:27
@wan9chi wan9chi changed the base branch from graphite-base/450 to infra-get-envs-ipc June 13, 2026 14:27
@wan9chi wan9chi force-pushed the infra-get-envs-ipc branch from 01ea610 to 399692e Compare June 13, 2026 14:37
@wan9chi wan9chi force-pushed the infra-get-envs-fingerprint branch 2 times, most recently from 9705c8f to 9477718 Compare June 13, 2026 15:58
@wan9chi wan9chi force-pushed the infra-get-envs-ipc branch from 399692e to 25a3219 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-envs-ipc branch from 25a3219 to 97aa3f0 Compare June 13, 2026 16:01
@wan9chi wan9chi force-pushed the infra-get-envs-fingerprint branch from 9477718 to a183557 Compare June 13, 2026 16:01
@wan9chi wan9chi force-pushed the infra-get-envs-ipc branch from 97aa3f0 to 32ac35f Compare June 13, 2026 16:03
@wan9chi wan9chi force-pushed the infra-get-envs-ipc branch from de59cd5 to eeef562 Compare June 13, 2026 17:23
@wan9chi wan9chi force-pushed the infra-get-envs-fingerprint branch 2 times, most recently from e7f2878 to 7c7745e Compare June 13, 2026 17:27
@wan9chi wan9chi force-pushed the infra-get-envs-ipc branch from eeef562 to 48d54e2 Compare June 13, 2026 17:27
@wan9chi wan9chi changed the base branch from infra-get-envs-ipc to graphite-base/450 June 13, 2026 17:44
@wan9chi wan9chi force-pushed the infra-get-envs-fingerprint branch from 7c7745e to 0eb3c8f Compare June 13, 2026 17:45
@wan9chi wan9chi force-pushed the graphite-base/450 branch from 48d54e2 to af162e1 Compare June 13, 2026 17:45
@wan9chi wan9chi changed the base branch from graphite-base/450 to infra-get-envs-ipc June 13, 2026 17:45
@wan9chi wan9chi changed the base branch from infra-get-envs-ipc to graphite-base/450 June 13, 2026 17:49
@wan9chi wan9chi force-pushed the graphite-base/450 branch from af162e1 to 4b5fc3a Compare June 13, 2026 17:49
@wan9chi wan9chi force-pushed the infra-get-envs-fingerprint branch from 0eb3c8f to ea1905d Compare June 13, 2026 17:49
@wan9chi wan9chi changed the base branch from graphite-base/450 to infra-get-envs-ipc June 13, 2026 17:49
@wan9chi wan9chi changed the base branch from infra-get-envs-ipc to graphite-base/450 June 14, 2026 02:35
@wan9chi wan9chi force-pushed the graphite-base/450 branch from 4b5fc3a to 7c57306 Compare June 14, 2026 02:37
@wan9chi wan9chi force-pushed the infra-get-envs-fingerprint branch from ea1905d to f5a544c Compare June 14, 2026 02:37
@wan9chi wan9chi changed the base branch from graphite-base/450 to infra-get-envs-ipc June 14, 2026 02:37
@wan9chi wan9chi force-pushed the infra-get-envs-ipc branch 2 times, most recently from 74369aa to 0ca4783 Compare June 14, 2026 02:38
@wan9chi wan9chi force-pushed the infra-get-envs-fingerprint branch from f5a544c to d5426a1 Compare June 14, 2026 02:38
@wan9chi wan9chi force-pushed the infra-get-envs-ipc branch from 0ca4783 to 915a5a0 Compare June 14, 2026 02:58
@wan9chi wan9chi force-pushed the infra-get-envs-fingerprint branch from d5426a1 to c4ab894 Compare June 14, 2026 02:58
@wan9chi wan9chi force-pushed the infra-get-envs-fingerprint branch from c4ab894 to 52280ec Compare June 14, 2026 06:35
@wan9chi wan9chi force-pushed the infra-get-envs-ipc branch from 915a5a0 to 397dcba Compare June 14, 2026 06:35
@wan9chi wan9chi force-pushed the infra-get-envs-fingerprint branch from 52280ec to 1604709 Compare June 14, 2026 06:37
@wan9chi wan9chi force-pushed the infra-get-envs-ipc branch from 397dcba to 983bc76 Compare June 14, 2026 06:38
@wan9chi wan9chi force-pushed the infra-get-envs-fingerprint branch from 1604709 to 869ce93 Compare June 14, 2026 06:38
Motivation:
Bulk env reads are only cache-safe if the cache remembers the entire matched env set. Without match-set fingerprinting, changing a matching env value, adding a new matching name, or removing one could replay stale output.

Scope:
Make the getEnvs tracked option meaningful, record tracked match sets in IPC reports, store them in the post-run fingerprint, validate changed/added/removed matches during cache lookup, and render env-specific miss messages. This PR does not add the real Vite fixture.

Verification:
- cargo test -p vite_task_server --test integration
- UPDATE_SNAPSHOTS=1 cargo test -p vite_task_bin --test e2e_snapshots fetch_envs_tracks_glob_match_set -- --ignored
- cargo test -p vite_task_bin --test e2e_snapshots fetch_envs_tracks_glob_match_set -- --ignored
@wan9chi wan9chi force-pushed the infra-get-envs-ipc branch from 983bc76 to 930e359 Compare June 14, 2026 08:34
@wan9chi wan9chi force-pushed the infra-get-envs-fingerprint branch from 869ce93 to 9cb33a2 Compare June 14, 2026 08:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant