G0: cell substrate — invariants made executable
Strand G0 complete and VERIFIED against real Postgres, not asserted.
- FastAPI plane, fail-closed provider seams, repair-pointer error taxonomy
- migration 001: all 10 tables incl. repo_type NOT NULL and model_cards (I-7)
- 17 invariant tests, ruff clean, vocabulary audit clean
Two bugs found by RUNNING it that review would not have caught:
1. SQLAlchemy Enum persists .name, not .value — so RepoState.deleted_soft
and CreatedVia.imported would have written labels migration 001 never
declared, failing at runtime rather than at review. Pinned via
values_callable.
2. op.create_table asks each Enum to emit its own CREATE TYPE with no
checkfirst, so the second reference raised DuplicateObject and the
migration died halfway. Types are now created once, referenced with
create_type=False.
Proven live, with the hostile env var set:
- I-12: COMMIT_SHA=deadbeef... in the environment, /version reports real HEAD.
That env pin is the documented root cause of nine sibling services
misreporting their commit; here it is structurally ignored.
- I-8: three unconfigured providers -> status degraded, HTTP 503, each saying
'refusing to report healthy'. No mock, no false green.
- G0.4: upgrade -> downgrade -> upgrade round-trip clean (10 -> 0 -> 10).
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This commit is contained in:
33
.env.example
Normal file
33
.env.example
Normal file
@@ -0,0 +1,33 @@
|
||||
# windy-git — copy to .env. NEVER commit the real file.
|
||||
# Providers fail CLOSED (I-8): leave a credential unset and that provider
|
||||
# reports itself unconfigured rather than answering from a mock.
|
||||
|
||||
ENVIRONMENT=development
|
||||
PORT=8600
|
||||
|
||||
DATABASE_URL=postgresql+asyncpg://windygit:windygit@localhost:5432/windygit
|
||||
|
||||
# Gitea — a COMPONENT behind an API membrane, never a merged tree (D-2/I-1)
|
||||
GITEA_BASE_URL=http://localhost:3000
|
||||
GITEA_ADMIN_TOKEN=
|
||||
|
||||
# Cloudflare R2 — heavy bytes ONLY. Never git object stores (I-3).
|
||||
R2_ACCOUNT_ID=193b347aedeaafe35de0b5a534b2d9aa
|
||||
R2_ACCESS_KEY_ID=
|
||||
R2_SECRET_ACCESS_KEY=
|
||||
R2_BUCKET_LFS=windy-git-lfs
|
||||
R2_BUCKET_ARTIFACTS=windy-git-artifacts
|
||||
R2_BUCKET_BACKUPS=windy-git-backups
|
||||
|
||||
# Eternitas — the one issuer
|
||||
ETERNITAS_BASE_URL=https://api.eternitas.ai
|
||||
ETERNITAS_PLATFORM_API_KEY=
|
||||
|
||||
# account-server OIDC — human identity
|
||||
ACCOUNT_SERVER_BASE_URL=https://account.windyword.ai
|
||||
|
||||
# I-3: git object databases live on a POSIX filesystem, full stop.
|
||||
GIT_DATA_ROOT=/srv/windygit/git
|
||||
|
||||
# COMMIT_SHA is deliberately NOT here. Setting it does nothing — the sha is
|
||||
# baked into the image at build time and a runtime override is ignored (I-12).
|
||||
Reference in New Issue
Block a user