Skip to content

docs: add CLAUDE.md documenting the local pre-push gate - #186

Draft
hunleyd wants to merge 2 commits into
mainfrom
hunleyd/docs/add-claude-md-build-test-lint
Draft

docs: add CLAUDE.md documenting the local pre-push gate#186
hunleyd wants to merge 2 commits into
mainfrom
hunleyd/docs/add-claude-md-build-test-lint

Conversation

@hunleyd

@hunleyd hunleyd commented Sep 3, 2026

Copy link
Copy Markdown

Summary

Adds a CLAUDE.md documenting what this repo is and its local pre-push gate: pre-commit run --all-files and the docker-compose pg_regress suite. Every command in the file was run for real against this repo, not just read from the workflow YAML.

(bot-generated information collapsed below)


Details
  • splinter had no CLAUDE.md at all before this PR.
  • A correctness and a spec-fidelity review pass each independently found the same real bug in the first draft: PG_VERSION never selects a Postgres version, since dockerfiles/docker-compose.yml only reads SUPABASE_VERSION for its build arg (confirmed via docker compose config with both variables set). The file now documents the working form, matching this repo's own README and .claude/skills/new-lint/SKILL.md.
  • Also corrected: the staleness advice named a trigger condition (a dependency/lockfile change) that can't occur in this repo, and omitted the real one (any lint/test/expected-file change); the black-version bullet told the reader to install black in a venv when pre-commit already manages that itself; the hygiene-hook list was missing check-added-large-files.
  • Both documented commands were re-run for real after the fixes: pre-commit run --all-files (8/8 hooks passed) and the docker-compose pg_regress suite (28/28 tests passed).

Resolves https://linear.app/supabase/issue/INDATA-1481

Names the two local checks CI runs: pre-commit run --all-files (black
pinned to 24.2.0, bin/compile.py, bin/check_lints.py, hygiene hooks) and
the docker-compose pg_regress suite. Every command verified against the
repo's own .pre-commit-config.yaml and .github/workflows/*.yaml.
@hunleyd hunleyd self-assigned this Sep 3, 2026
…DE.md

PG_VERSION never selects a Postgres version -- dockerfiles/docker-compose.yml
only reads SUPABASE_VERSION for its build arg, verified via docker compose
config with both vars set. The rmi-first staleness fix and --rm flag now
match the repo's own README/new-lint skill convention. Pre-commit builds
its own isolated black env from the pinned rev, so the venv-install
instruction was actively wrong; added the real prerequisite (python3.12 on
PATH) instead. Also names bin/compile.py's tracked output (splinter.sql)
and completes the hygiene-hook list.

Every documented command re-run for real (pre-commit run --all-files: 8/8
hooks passed; the docker test suite: 28/28 tests passed) after this edit.
@hunleyd
hunleyd marked this pull request as ready for review September 3, 2026 16:40
@hunleyd

hunleyd commented Sep 3, 2026

Copy link
Copy Markdown
Author

@claude review

@claude claude Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM — this adds a new CLAUDE.md documentation file with no code changes.

What was reviewed: verified the described pre-commit hooks (black 24.2.0/python3.12, compile.py, check_lints.py, hygiene hooks) against .pre-commit-config.yaml; verified the PG_VERSION vs SUPABASE_VERSION claim against .github/workflows/test.yml and dockerfiles/docker-compose.yml; confirmed docker-compose.yml only reads SUPABASE_VERSION for the build arg, matching the described no-op behavior. All factual claims in the new file check out.

Extended reasoning...

Overview

The diff adds a single new file, CLAUDE.md, containing guidance for Claude Code sessions working in this repo: an overview of what splinter does, and two subsections describing the local pre-commit gate and the docker-based pg_regress test suite. No source code, SQL lints, scripts, or CI workflows are modified.

Security risks

None. This is a documentation-only change with no executable code, no secrets, and no changes to build or CI configuration.

Level of scrutiny

Low. This warrants a light-touch factual check: does the documentation accurately describe the repository's actual tooling and CI behavior? I cross-checked every specific claim (hook versions, script names, env var behavior, the "docker rmi -f is required not optional" caveat) against .pre-commit-config.yaml, .github/workflows/pre-commit_hooks.yaml, .github/workflows/test.yml, and dockerfiles/docker-compose.yml, and all matched.

Other factors

No CODEOWNERS restriction found on CLAUDE.md, no prior review history to weigh, and no findings were reported by the bug hunt. This is exactly the kind of small, self-contained, mechanical change (docs addition, verifiably accurate) that merits approval without requiring further human review.

@hunleyd
hunleyd marked this pull request as draft September 8, 2026 20:00
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