Skip to content

A person's change puts a folder where a file stands and a file where an empty folder stands - #265

Merged
SitgesRun merged 1 commit into
stagingfrom
a4-fix-forward-2
Nov 16, 2026
Merged

SitgesRun merged 1 commit into
stagingfrom
a4-fix-forward-2

Conversation

@SitgesRun

Copy link
Copy Markdown
Contributor

These are the fixes for Codex's read-only review of #264 (c76a4c4), one commit on staging c76a4c4.

Codex finding Fix
Restoring historical sub/a.md where sub is now a file threw ENOTDIR in throughNoLink, before the deletions ran placement.ts realTarget judges a path below a file (ENOTDIR) as it judges a path not there (ENOENT): by what is there
Restoring a file over an empty folder failed: git lists no file in it to delete a person's change removes an empty folder where it writes a file (rmdir, which refuses one that is not empty)

Size: production 2 files, +4/−1; test +10.

Gates

  • Failing-first (73c3a54): the test only, on c76a4c4, FAILED 1 of 338, the extended Use test. The other 336 passed.
  • This head 475ab69: pine-dev PASSED in 100 s. npm test: 338 tests, 337 pass, 0 fail, 1 skipped. Render smoke: 30 of 30 pages (run 20261116T011440-475ab696).

…an empty folder stands

Codex's read-only review of #264 (c76a4c4):

- placement.ts realTarget judges a path below a file (ENOTDIR) as it judges a
  path not there (ENOENT): by what is there. So restoring historical sub/a.md
  where sub is now a file passes the link check, and the change's deletion of
  the file comes first.
- An empty folder where a file is written, which git does not hold and no
  deletion names, is removed first (rmdir, which refuses a folder that is not
  empty).

Signed-off-by: SitgesRun <169425442+SitgesRun@users.noreply.github.com>
@SitgesRun
SitgesRun merged commit 475ab69 into staging Nov 16, 2026
1 check passed
@SitgesRun
SitgesRun deleted the a4-fix-forward-2 branch November 16, 2026 01:16
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