Repository navigation
docs(tasks): file commit accepting logical paths that conflict - #4
Merged
adammharris merged 1 commit intoOct 28, 2026
Merged
Conversation
adammharris
deleted the
agent/backlog-commit-accepts-conflicting-logical-paths
branch
October 30, 2026 01:26
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.
Files a new task,
docs/tasks/commit-accepts-conflicting-logical-paths.md, and lists it indocs/tasks/tasks.md. No code changes.The defect
Object::commitchecks each logical path on its own and never checks them against each other. OCFL 1.1 forbids a version whose logical paths repeat, or where one is a prefix of another (E095). The same rule applies to content paths (E101). Each of three cases gets through:Ok. Both digests map tov1/content/a, and the second write replaces the first.validatereports nothing.validate_deepreportsContentDigestMismatch.aanda/bin one commit: the commit fails withIo(AlreadyExists)afterv1/content/ais already on disk. This contradictscommit's own "fails before it has written half a version".ain v1, thena(same bytes) plusa/bin v2: the commit returnsOk, andvalidatereports nothing. The resulting state is forbidden by E095, and no filesystem can hold it.The CLI cannot reach any of these, because a directory walk yields each path once. A library caller passing its own list can.
How it was found and checked
I found this by reading
commitagainst the spec, then reproduced each case with a throwaway integration test againstmain(e97e69f). The task records the observed results. I checked the E095 and E101 wording against https://ocfl.io/1.1/spec/validation-codes.html. Onmain,cargo clippy --all-targets -- -D warningsandcargo testare green.prov checkreports the same single pre-existing finding (about.md: not written) with and without this change.