fix(fsio): a move takes the destination's old size out of the usage total (#1119) #1164

Closed
kayg wants to merge 0 commits from fix/flake-1119 into dev
Owner

Fixes #1119 (and #1021, the same +137 once). A move onto a name the recount walk had already counted now takes the old size out of the total.

Cause, red test and gates are in the #1119 comment. Two commits: the test alone (fails 274 != 137), then the fix.

Perf: none; moved() uses the return value of an insert it already did.

🤖 Generated with Claude Code

Fixes #1119 (and #1021, the same +137 once). A move onto a name the recount walk had already counted now takes the old size out of the total. Cause, red test and gates are in the #1119 comment. Two commits: the test alone (fails `274 != 137`), then the fix. Perf: none; `moved()` uses the return value of an insert it already did. 🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
fix(fsio): a move takes the destination's old size out of the total (#1119, #1021)
Some checks failed
CI / server (pull_request) Has been cancelled
CI / rust (pull_request) Has been cancelled
CI / web (pull_request) Has been cancelled
Markdown extraction contract / markdown-native-contract (pull_request) Has been cancelled
Markdown extraction contract / markdown-editor-contract (pull_request) Has been cancelled
97b5d7e803
A recount that walks a folder while a file is renamed in it can list both
names and publish the file twice. The move that follows added the size
again without taking the old entry out, so the file stayed counted twice
until the next recount (about 60 s).

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Author
Owner

Gates (dev-02, one slot job each, head 97b5d7e80): cargo fmt --check -p calternal-fsio clean; cargo clippy -j4 --locked -p calternal-fsio --all-targets -- -D warnings clean; cargo test -j4 --locked -p calternal-fsio 54 passed; cargo test -j4 --locked -p calternal-auth all green. The new test fails on 2eaf7a4f7 (left: 274, right: 137) and passes on 97b5d7e80. No JS changed (svelte-check and vitest not applicable). Perf: none expected, see #1119.

Gates (dev-02, one slot job each, head `97b5d7e80`): `cargo fmt --check -p calternal-fsio` clean; `cargo clippy -j4 --locked -p calternal-fsio --all-targets -- -D warnings` clean; `cargo test -j4 --locked -p calternal-fsio` 54 passed; `cargo test -j4 --locked -p calternal-auth` all green. The new test fails on `2eaf7a4f7` (`left: 274, right: 137`) and passes on `97b5d7e80`. No JS changed (svelte-check and vitest not applicable). Perf: none expected, see #1119.
Author
Owner

Merged into dev with --no-ff (orchestrator, 16 Nov ~07:00 IST) after reviewing the diff and the red/green test.

Merged into dev with `--no-ff` (orchestrator, 16 Nov ~07:00 IST) after reviewing the diff and the red/green test.
kayg closed this pull request 2026-11-16 00:53:16 +00:00
Some checks failed
CI / server (pull_request) Has been cancelled
CI / rust (pull_request) Has been cancelled
CI / web (pull_request) Has been cancelled
Markdown extraction contract / markdown-native-contract (pull_request) Has been cancelled
Markdown extraction contract / markdown-editor-contract (pull_request) Has been cancelled

Pull request closed

Sign in to join this conversation.
No reviewers
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
kayg/calternal!1164
No description provided.