fix(core): restore backup-only file-tree hiding reverted by #1389#1402
Closed
jrusso1020 wants to merge 1 commit into
Closed
fix(core): restore backup-only file-tree hiding reverted by #1389#1402jrusso1020 wants to merge 1 commit into
jrusso1020 wants to merge 1 commit into
Conversation
main has been red since #1389 (3bcab3d). #1389 ("reject unsafe keyframe values") is unrelated to studio composition discovery, but it branched off pre-#1366 main and its squash reverted #1366's walkDir refinement: it put `.hyperframes` back into IGNORE_DIRS and dropped `shouldIgnoreDir`, so the whole `.hyperframes/` tree is hidden again instead of just `.hyperframes/backup`. That re-broke #1366's intent (vendored dot-dir HTML must stay browsable in the file tree, gated only out of composition discovery), so the file-tree test from #1400 fails. Restore #1366's behavior while keeping #1397's `isSafePath` promotion: - IGNORE_DIRS back to `.thumbnails`/`node_modules`/`.git` (no `.hyperframes`). - Reinstate `shouldIgnoreDir(rel) === ".hyperframes/backup"` and the `|| shouldIgnoreDir(rel)` guard in walkDir. - Realign the walkDir test to assert `.hyperframes/examples` stays visible and only `.hyperframes/backup` is hidden (it had been flipped to hide all `.hyperframes` by the same revert). Full non-producer suite green. NOTE: studio-api/helpers/safePath.ts is a recurring conflict hotspot — #1366's fix has now been reverted twice by stale-base PRs (#1389, and earlier #1399). Worth landing in-flight branches on current main before squashing. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Collaborator
Author
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
mainis red (CI / Test) and has been since #1389 (3bcab3d). This restores green. Small, mostly test-only (2-line helper change).Why
#1389 ("reject unsafe keyframe values") is unrelated to studio composition discovery, but it branched off pre-#1366
mainand its squash reverted #1366'swalkDirrefinement:.hyperframeswent back intoIGNORE_DIRSandshouldIgnoreDirwas dropped, so the entire.hyperframes/tree is hidden again instead of just.hyperframes/backup.That breaks #1366's intent (vendored dot-directory HTML stays browsable in the file tree, gated only out of composition discovery), so the file-tree test from #1400 fails on
main. The helper and thewalkDirtest ended up in the "hide-all-.hyperframes" world whileprojects.test.ts(#1400) is in the "hide-only-backup" world — an incoherent mix.How
Restore #1366's behavior, keeping #1397's
isSafePathpromotion:IGNORE_DIRS→.thumbnails/node_modules/.git(drop.hyperframes).shouldIgnoreDir(rel) === ".hyperframes/backup"+ the|| shouldIgnoreDir(rel)guard inwalkDir.walkDirtest to assert.hyperframes/examplesstays visible and only.hyperframes/backupis hidden.Test plan
projects.test.ts,safePath.test.ts(walkDir),lint.test.tspass.bun run --filter '!@hyperframes/producer' testgreen (exit 0);oxlint/oxfmt --checkclean.🤖 Generated with Claude Code