chore: remove vestigial .capy/decrypt key cluster#226
Merged
Conversation
The .capy/decrypt file-based key source is no longer used at runtime — capy run injects secrets via the spawned process env (local mode) or SECRETS_BLOB + PROJECT_KEY (deployed mode). The leftover machinery was dead code: - ProjectManager.getDecryptPath() / readDecryptKey() — no callers - ProjectManager.detectProjectState() computed hasDecryptKey, but nothing read it - FileManager.writeDecryptKey() — no callers - SyncEngine.createDecryptKey() — no callers - DecryptKey type and ProjectState.hasDecryptKey field — used only by the above Removes the code, the type surface, and all test references. No behavior change: src typechecks clean and the full suite passes (394 pass / 0 fail).
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.
What
Removes the dead
.capy/decryptfile-based key-source machinery. It is no longer used at runtime —capy runinjects secrets via the spawned process env (local mode) orSECRETS_BLOB+PROJECT_KEY(deployed mode). The leftover code had zero runtime consumers:ProjectManager.getDecryptPath()/readDecryptKey()— no callersProjectManager.detectProjectState()computedhasDecryptKey = existsSync('.capy/decrypt'), but nothing ever read the fieldFileManager.writeDecryptKey()— no callersSyncEngine.createDecryptKey()— no callersDecryptKeytype andProjectState.hasDecryptKeyfield — used only by the aboveScope
Removes the code, the type surface, and all test references to the cluster (
hasDecryptKey,DecryptKey,getDecryptPath,readDecryptKey,writeDecryptKey,createDecryptKey,.capy/decrypt). 10 files, +10 / −239.Verification
bun run typecheck— cleanbash tests/run-tests.sh— 394 pass / 0 fail (exit 0)The
gitignorehelper tests that used.capy/decryptas sample data were kept valid by swapping it out and keeping input/expected in sync.