Skip to content

chore(repo): untrack result artifacts + path-lint CI + branch protection#101

Open
rsasaki0109 wants to merge 3 commits into
mainfrom
chore/repo-hygiene-untrack-results
Open

chore(repo): untrack result artifacts + path-lint CI + branch protection#101
rsasaki0109 wants to merge 3 commits into
mainfrom
chore/repo-hygiene-untrack-results

Conversation

@rsasaki0109

Copy link
Copy Markdown
Owner

Hardens the repo against the 2026-06-17 incident (local main diverged into an unrelated history, then git reset --hard failed on Windows because tracked sweep filenames exceeded the 260-char MAX_PATH limit).

Changes

  • Untrack regenerable result artifacts — removes 982 data files (csv/pos/npz/gz, ~226 MB) under experiments/results from the index. 16 had paths >180 chars (max 266). Longest path drops 266 → 92 chars. Media, docs, and paper_assets stay tracked. History retains everything; this only untracks them.
  • path-lint CItools/lint_repo_paths.py (caps path length 180 / basename 96, forbids tracked generated artifacts under experiments/results), wired into CI on ubuntu + windows. The windows leg is a canary: an over-long tracked path fails at checkout.
  • Branch protection.githooks/pre-push (blocks direct push to main; refuses branches not based on origin/main) + a Git workflow section in CONTRIBUTING.md documenting per-clone config and the GitHub branch-protection settings to apply.

🤖 Generated with Claude Code

rsasaki0109 and others added 3 commits June 17, 2026 03:31
… length

Untracks 982 data artifacts (csv/pos/npz/gz, ~226MB) under experiments/results
that are regenerable via the CLIs recorded in plan.md. 16 of them had paths
>180 chars (max 266), exceeding the Windows MAX_PATH 260 limit and breaking
`git reset --hard` / clean clone on Windows (core.longpaths was only a band-aid).

Media (png/mp4/gif/webm/html/kml), docs (md/txt), and paper_assets remain
tracked. Longest path under experiments/results drops 266 -> 92 chars.
History retains the files; this only removes them from the working tree index.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Adds tools/lint_repo_paths.py (caps tracked path length at 180 / basename at 96,
forbids tracked generated artifacts under experiments/results) and wires it into
CI on ubuntu + windows. The windows leg is a canary: an over-long tracked path
fails at checkout before the lint runs, catching the 260-char breakage class.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Adds .githooks/pre-push (blocks direct push to main; refuses branches not based
on origin/main) and a Git workflow section in CONTRIBUTING.md covering the
per-clone config (pull.ff only, core.hooksPath, core.longpaths) and the GitHub
branch-protection settings. Hardens against the 2026-06-17 unrelated-history +
Windows MAX_PATH incident.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@rsasaki0109 rsasaki0109 force-pushed the chore/repo-hygiene-untrack-results branch 2 times, most recently from 481b1d6 to 687f8ab Compare June 17, 2026 15:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant