Repository navigation
steam-sharing: copy Steam's shader record along with the cache - #36
Merged
Merged
Conversation
Each Steam client keeps its own record of a game's shader cache in config/config.vdf (ShaderCacheManager: CommittedDepotManifests, ProcessingQueue, ShaderCacheSize, CompatToolBucketHashes). A cache copied by steam-copy-game or steam-shader-sync arrived without it, so the receiver's Steam kept the game queued and replayed every pipeline again. On kamrui-h1 that was wife's Overwatch: 1.8M pipelines (hours) although her copy already held the compiled shaders. steam-shader-record (_steam-shader-record.py) now writes the source's record of the game into the receiver's config.vdf, while the receiver's Steam is closed; the game stays queued only if it was for the source. VM test steam-sharing: the record follows steam-copy-game and the sync. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
andrewthomaslee
added a commit
to external-systems/home
that referenced
this pull request
Nov 10, 2026
## Summary ```diff flake.lock modules 3c31dde → 079b331 (external-systems/modules#36) ``` `steam-copy-game` and `steam-shader-sync` now also copy Steam's record of a shader cache (`config.vdf`, `ShaderCacheManager`), so the receiver's Steam doesn't replay it again. On kamrui-h1 that's wife's Overwatch: 1.8M pipelines. ## Evidence - **Before:** wife's `config.vdf` had `"ProcessingQueue" "2357570;"`, and her Steam replayed `0/1797888` pipelines at launch. **After:** modules `vm-test steam-sharing` → passed (the record follows the copy). Home `check` → all checks passed. `nix build .#nixosConfigurations.kamrui-h1.config.system.build.toplevel` → `y6vlrz9s…-nixos-system-kamrui-h1`, with `steam-shader-record` on `steam-copy-game`'s PATH. - Still to do after deploy: the next `steam-shader-sync` run, or `steam-copy-game --force`, writes wife's record, and her Steam then starts without "Processing Vulkan shaders". ## Merge Danger **Door:** two-way **Blast Radius:** kamrui-h1 Only the users' Steam `config.vdf` `ShaderCacheManager` section is rewritten, and only while that user's Steam is closed. 🤖 Generated with [Claude Code](https://claude.com/claude-code) --------- Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
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.
Summary
A copied shader cache now carries Steam's own record of it, so the receiver's Steam doesn't process it again.
Evidence
config.vdfhad"ProcessingQueue" "2357570;"and no record of the GE-Proton pipeline buckets. Her Steam replayedsteamapprun_pipeline_cache.049c…:Still replaying 2357570 (33%, 11746/1800301), about 230 pipelines/s, so hours of work. netsa's record had an empty queue, so his Steam didn't replay.After: a dry run on a copy of netsa's real
config.vdfwrites the 2357570 depots, size and buckets into a fake receiver config and empties its queue.vm-test steam-sharing→ passed, with a new subtest: "Steam's record of the shader cache follows the copy". It also checks that a game the source still has queued stays queued, that the file keeps its owner and mode, and that the sync copies the record too.check→ all checks passed.Merge Danger
Door: two-way
Only the receiver's
config.vdf(ShaderCacheManagersection) is rewritten, and only while their Steam is closed. Reverting stops further rewrites. A wrong record only makes Steam download or process a cache again.Blast Radius: steam-sharing
Machines with
hostSpec.system.gaming.steamSharing(kamrui-h1). The file is re-serialized by pythonvdf, with a space instead of two tabs between key and value. Steam's KeyValues parser should accept that, and Steam rewrites the file in its own format when it exits. This hasn't been tried on a real Steam yet: that is checked on kamrui-h1 after deploy (wife's Steam starts without processing Overwatch).🤖 Generated with Claude Code