Repository navigation
Let declared file owners identify installer rewrites - #2691
Merged
10 commits merged intoOct 23, 2026
Merged
10 commits merged into
10 commits merged into
Conversation
trissim
force-pushed
the
next/installer-file-identity
branch
from
October 23, 2026 08:53
eec37de to
1a6fc31
Compare
trissim
marked this pull request as ready for review
October 23, 2026 09:09
There was a problem hiding this comment.
Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.
An organization owner can choose the repository organization as the billing source for reviews requested by members with a paid Copilot license. Learn about Copilot code review billing.
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.
The installer guessed file identity from suffixes even though RootFile already owns storage behavior. A nonempty WAL now changes its SQLite resource's snapshot; the installer never strips four characters off a name. Carry reports, rehearsal lists and reconcile results carry root-relative Path values through PathText.
RootFile.owned_files derives the declaration and content behavior for each selected resource, folds SQLite content companions and excludes declared transient lock/journal resources. DeclaredFile stores the declaring class plus one retained path. UndeclaredFile stores a path without pretending it has a declaration. SQLiteFile owns WAL naming, transient companions and which content members enter a physical snapshot. Durable snapshot intent and change-marker files stay visible and copied; they are not confused with transient locks. The inventory and StoreBackup.take use the same owner operation, so selecting a database plus its WAL produces one logical database backup, not a database snapshot followed by a raw WAL copy.
bus_files records typed resource keys and the physical metadata of their content members. carried compares those groups and reports their primary paths, using the same membership to fold declared rewrite paths. Restore reservation includes the previous group's content bytes. No filename endswith or filename slice remains in installer code. Backup manifests decode JSON path strings once at their boundary; the retained JSON object/array shapes stay unchanged. Restore asks the saved file's content owner before removing storage companions, so restoring a plain file no longer deletes unrelated SQLite-shaped neighbours.
Carry is a DeclaredFamily with cutover-package discovery. Carry.declared, its handwritten collision check, its module-stem name alias and the second manual import walk are deleted. CarryChain reads family members filtered by directory; Git first-parent source-file chronology still orders independent steps, and class dependencies order required predecessors. step_worker selects through Carry.member_named. The existing metaclass registry owns duplicate-name rejection; this PR adds no registry or duplicate check. Main's batched worker remains: one interpreter per pass, not one per step.
All cutover rewrite producers use Paths, including the newly landed ThreadNameOwners. MI owns carry_claim_fields.py and carry_declared_failures.py; their Path updates arrived through main and are preserved. The rest of the cutover producers, reconciliation boundary and existing worker fixtures are migrated here. No old-name alias or parallel decoder is retained.
Source checks: the requested git grep over src/agent_comms/installer returns zero matches for rewritten: tuple[str, the lock suffix check and name[:-4]. Carry.declared and step.name() have no remaining production/cutover consumers. git diff --check is clean. Reading the actual Carry registry imported these ten source modules:
Merged origin/main 05fcdfe (#2701), resolving worker conflicts by keeping the batched transport and replacing only its step identity with the declaration. Main's files outside this change stay intact. Diff against that main: 128 lines deleted, 209 added across 18 files. The commander runs the affected installer/carry batch; no unit suite ran.
Assumed: rewrite paths are relative to the bus root; RootFile declarations identify known resources and content_owner supplies behavior for undeclared regular files. SQLite snapshots own database/WAL consistency; empty WALs, locks, SHM and rollback journals do not represent a separate retained file. Durable uncertainty intent files remain separate retained content. Migration/rollback holds maintenance and stops predecessor writers. Carry tags derive from class declarations rather than old module-name aliases; caller and target worker move together. Git chronology remains the intended tie-break for independent carry steps.