Skip to content

Proposal: git second leg for workspace/scratch (+ untrack hygiene-scratch) — core-file backup coverage #6100

Open

Description

@dezren39

Proposal — git as a second backup leg for the core knowledge files (from 2026-11-05 file-state investigation)

Current coverage (verified 2026-11-05; full evidence in the investigation report)

Class Disk hatch-personal git (→ GitHub) Restic → R2
research_notes (172 files / 24 MB) ✅ ✅ 172/172 tracked ✅
memory topics (71 files) ✅ ✅ 71/71 tracked ✅
goal files/ (348 files) ✅ ✅ 348/348 tracked ✅
goal hidden_files records ✅ ✅ tracked except deliberately-ignored regenerables (probe-/clone-/monitor-/wt-, node_modules) ✅
workspace/scratch (803 files / 104 MB; 221 .md ≈ 0.9 MB) ✅ ❌ tracked nowhere in git ✅ (only backup leg)

Drew's concern ("core files… supposed to be kept forever") is well-aimed at exactly one class: scratch — tonight's briefs/designs (worlds, atlas, docs-migration, modal, mistral) live there and have no git leg. Research notes, topics, and goal records already have three legs (disk + private git + restic/R2).

Proposal

  1. Bring scratch under hatch-personal git using the existing pattern: relocate the real tree to hatch-personal/workspace/scratch with /home/hatch/workspace/scratch as a symlink — identical to how goals/ and research_notes/ were relocated on 2026-10-25. The per-minute autocommit then tracks it with zero new machinery.
  2. Track records, ignore bulk: add scratch entries to git for documents and small data (md/txt/json under ~1 MB each); gitignore large regenerable payloads inside scratch subdirs (model/data dumps). Starting point: 221 md files ≈ 0.9 MB — the entire current markdown corpus is trivially small. Nothing in scratch today exceeds sane git size except raw data payloads, which restic already covers.
  3. Close the hygiene-scratch hole in the same change (see the companion security issue): add workspace/goals/*/hidden_files/hygiene-scratch/ to .gitignore + untrack — regenerable inventory dumps do not belong in git and demonstrably capture credential material.
  4. Promotion convention (Drew's stated end state): scratch is a staging area, not a home. At task close, durable deliverables get promoted — research/design docs toward developing-today/code doc/ (per the docs-migration batches, tracker Docs migration: hatch-personal/hatch/darwin-nix → code canonical home (tracking) #5983) or into research_notes — and the scratch dir is discarded. Truly sensitive material stays in hatch-personal only.
  5. Do not bulk-add the 9.3 GB goals tree to git: the current split (records tracked, regenerable probe/clone/monitor trees ignored per .gitignore lines 59–75) is correct and should be kept as documented policy.

No files were moved or re-tracked by the investigation itself — this issue is the work order for steps 1–3 when Drew approves.

Acceptance criteria

  • A decision on this proposal is recorded on this issue (adopt / adopt-modified / decline) with the reasoning.
  • If adopted: workspace/scratch's knowledge files (the ~221 markdown files at minimum) are tracked by the git second leg, with ignore rules excluding bulk/binary scratch, and hygiene-scratch is untracked as proposed.
  • A restore drill from the git leg alone succeeds for a sample of the newly covered files.
  • The coverage table in the body is updated to the post-change state (git column no longer empty for the covered classes).

Activity

  1. developing-today commented on Nov 5, 2026

    @developing-today
    Contributor
  2. added
    kind/designA design proposal (design-architect): multi-step, phased, decision-bearing
    source/humanFiled directly by a human
    priority/normalOrdinary priority (the default)
    effort/mMedium: expected under 1 day of work
    on Nov 5, 2026
  3. dezren39 commented on Nov 5, 2026

    @dezren39
    MemberAuthor

    Intake review

    No merged PR or duplicate issue referencing #6100 was found in a title/body search this run. The body's verified coverage table (2026-11-05 investigation) is the evidence base: restic already covers scratch, git does not.

    Notes: the gap is real but not urgent — one leg (restic→R2) already covers these files, hence priority/normal. Risk: tracking 104 MB of scratch wholesale would bloat the repo; the markdown-only scoping in the acceptance criteria is the safe shape. Suggested approach: decide, then implement the narrow git leg + untrack hygiene-scratch in one PR.

    — Fleet monitor intake (repo-fleet-monitor), 2026-11-05. Merged-PR title/body search count for this issue number at intake: 1.

  4. added
    meta/enrichedIntake review done: acceptance criteria, links, and normalized labels added
    queue/queuedHas a queued task in the Supabase agent queue
    task/triageQueue packet kind: verify, reproduce, and route this item
    work/assignedQueue worker lifecycle state
    queue/claimedQueue worker lifecycle state
    and removed
    queue/queuedHas a queued task in the Supabase agent queue
    on Nov 5, 2026
  5. dezren39 commented on Nov 5, 2026

    @dezren39
    MemberAuthor

    🤖 Agent note · escalated

    • Agent: queue worker (repo-worker-code), lane code-y
    • Session / ID: task 10446
    • Found via: queue claim
    • Task: Triage of issue Proposal: git second leg for workspace/scratch (+ untrack hygiene-scratch) — core-file backup coverage #6100 (proposal: git second leg for workspace/scratch + untrack hygiene-scratch). Reviewed first per protocol; the decision itself is Drew's by the issue's own terms ("the work order for steps 1–3 when Drew approves"; acceptance criterion 1 is a recorded adopt / adopt-modified / decline decision), so it escalates with my read attached.
    • Expectation: Drew records the decision on this issue; implementation (steps 1–2) follows as a separate work order if adopted.

    Worker review (verified 2026-11-05 against fresh state)

    • Step 3 is already done — by the companion security issue. Issue SECURITY: live GitHub PAT committed in hatch-personal hygiene-scratch dumps — revoke + untrack #6097 (SECURITY: live GitHub PAT committed in hatch-personal hygiene-scratch dumps — revoke + untrack) is CLOSED, and hatch-personal's .gitignore already carries the rule (lines 74–78, dated 2026-11-05, citing code#6097): workspace/goals/*/hidden_files/hygiene-scratch/ is ignored. So the untrack half of this proposal landed with the security fix; what remains for decision is steps 1–2 only. If adopted, this is effectively adopt-modified (steps 1–2; step 3 already satisfied).
    • The gap is as described: ~/workspace/scratch is still a plain directory with no git leg — restic→R2 is its only backup. The ~221 markdown files (≈0.9 MB) named in the proposal are tonight's briefs/designs (worlds, atlas, docs-migration) — the "kept forever" class.
    • Recommendation: adopt steps 1–2 as proposed. Reasons: (1) the relocation reuses the exact 2026-10-25 pattern already proven for goals/ and research_notes/ (real tree in hatch-personal, symlink at the workspace path, per-minute autocommit) — zero new machinery; (2) the markdown-only scoping keeps repo bloat negligible (~0.9 MB) and bulk payloads stay restic-only, answering the bloat risk the intake review raised; (3) the cost of declining is asymmetric — a sandbox recycle plus a restic gap loses unrecoverable design work, while the git leg is nearly free.
    • Options for the decision: adopt (steps 1–2 as written) / adopt-modified (e.g. different size threshold or file classes) / decline (accept restic-only coverage for scratch, with the risk stated above).
    • Task 10446 is blocked as escalated-to-user pending the recorded decision; the fleet monitor's intake note and the coverage table on this issue are the evidence base.
  6. added
    user/escalatedQueue or user escalation state
    queue/blockedQueue or user escalation state
    status/blockedQueue or user escalation state
    and removed
    queue/claimedQueue worker lifecycle state
    work/assignedQueue worker lifecycle state
    on Nov 5, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

effort/mMedium: expected under 1 day of workkind/designA design proposal (design-architect): multi-step, phased, decision-bearingmeta/enrichedIntake review done: acceptance criteria, links, and normalized labels addedpriority/normalOrdinary priority (the default)queue/blockedQueue or user escalation statesource/humanFiled directly by a humanstatus/blockedQueue or user escalation statetask/triageQueue packet kind: verify, reproduce, and route this itemuser/escalatedQueue or user escalation state

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions