Skip to content

OpenSpec: add-project-clean-cache-disposal (a merged worktree holding only Python bytecode caches is excluded from the batch as ignored-local-files) #24

Open

Description

@brettheap

Lane: openRepoProject-5

Governing issue for a new OpenSpec change, add-project-clean-cache-disposal, proposed on Brett Heap's word "usage reset, resume all. read handoff and resume and fan out wide and do as much as possible in parallel" (2026-10-11), which lanes openRepoProject-4 and openRepoProject-5 read as a go for the candidate list they had put to him, lane 5 taking the project-maintenance design packet's separately governed extensions (ideation/brainstorm/next-session-project-maintenance-fix-handoff.md:47-50 at da33d92). If that reading is wrong, closing this issue ends the change. Refs #6, the record of the packet.

Problem

The batch removes only worktrees with no ignored files, so a merged, clean worktree that holds nothing but Python bytecode caches (__pycache__ directories, .pyc and .pyo files) is excluded as ignored-local-files and stays on disk run after run. The council's survey found 102 of 561 rows excluded for ignored files and, in one repository, 20 of 29 merged worktrees excluded for caches alone (openspec/changes/add-project-clean-all-safe/proposal.md:73-75, :697-699; tasks 2.1). The ratified change names cache disposal "the first follow-on change". The packet keeps it out of the MVP and fixes its contract (project-maintenance-batch-cleanup.md:1314-1337 at da33d92): a symlink candidate or ancestor is ineligible; descriptor-relative, no-follow deletion with the opened directory's identity checked against the planned device and inode, failing closed where the platform cannot guarantee it; each cache path reported separately; a partial phase recorded as permanent partial completion with retry guidance; stop before any worktree or branch mutation when the cache preflight fails; hard caps on entries and bytes, counted in the plan estimate. The closed PR #2's commits 1789ad9 and bb91a49 are the harvest source; bb91a49's fd-relative deletes match part of that, but it checks no planned identity, has no caps, enumerates ignored files unbounded, and its whole-list preflight thread (3989548481) was open at the close.

Intended scope (for the proposal to settle)

A bounded cache stage before the removal of each selected worktree, inside the same deadline, with its own plan rows (paths with planned device and inode), caps in limits, a per-target sub-record in the versioned JSON, the whole-list preflight before the first unlink, and the ladder treating a worktree whose only ignored files are listed caches as removable; the allowlist is the two bytecode forms only.

Out of scope unless the proposal argues otherwise

Any other cache kind (.pytest_cache, .mypy_cache, node_modules, virtual environments); paired branch retirement and remote merge status (their own changes); the doctor and overview beyond what the shared ladder gives them; the CI matrix.

Sibling search

No open issue, PR, branch or active OpenSpec change covers this surface (searched for "cache", "pycache", "disposable", "ignored"). add-project-clean-all-safe (#9, PR #11, draft PR #19) and add-project-overview (#10, PR #12) are lane openRepoProject-2's; this change is written against their delta text and archives after change 1, before add-project-clean-branch-retirement. Draft PR #16 (lane 3) revises the packet; citations here pin da33d92. #20 (lane 1) touches project new only. PR #2 (closed) is the harvest source and is not reopened.

Activity

  1. brettheap commented on Oct 11, 2026

    @brettheap
    ContributorAuthor

    CLAIMED — lane openRepoProject-5, session 01e99fe7-bec0-4838-8159-eae2b41ad4ea@Eagle, 2026-10-11T16:34:17Z, for #24

    Logged in lanes/log/openRepoProject-5.md at f1afa5ce3020ddcfcf893968884e75b9141eb42e.

    The three reads (lane-collision-protocol Rule 1):

    1. existing `CLAIMED —` comments on opensoft/openRepoProject#24:
       none
    2. `gh pr list --repo opensoft/openRepoProject --state all --search "#24"`, kept where the row or its body names `#24`:
       none
    3. `git ls-remote --heads [email protected]:opensoft/openRepoProject` branches naming `23` as a whole token:
       none
    
  2. added 20 commits that reference this issue on Oct 20, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions