Skip to content

[settings-naming] guardrail: alias-aware env-var canon check (S13) #469

Description

@aptracebloc

Part of tracebloc/backend#3391 (settings-naming · S13 — the lightweight guardrail).

Add a reusable check (script + workflow + self-test) that keeps new code from regressing the settings-naming canon. Diff-scoped (added lines only), alias-aware, flags:

  • a NEW owned SCREAMING_SNAKE env var without the TRACEBLOC_ prefix — excluding externally-mandated names (AWS_*/AZURE_*/KUBECONFIG, the stock MySQL entrypoint contract MYSQL_ROOT_PASSWORD/MYSQL_DATABASE/MYSQL_USER/MYSQL_PASSWORD, Next.js NEXT_PUBLIC_, and common shell idioms NO_COLOR/TERM/CI/HTTP(S)_PROXY);
  • a NEW sole read of a retired stage name (CLIENT_ENV/EDGE_ENV/IN_ENV/TARGET_ENV) that is NOT paired with TRACEBLOC_ENV on/near the same line (so the sanctioned alias-fallback pattern PASSES — this is the load-bearing bit, avoid false-positives on legit alias code).

Scope for v1: land the reusable check + a self-test (plant a violation, assert red; plant the alias pattern, assert green) in this repo. Do NOT wire it into consumer repos yet — per-repo wiring is a follow-up after their in-flight settings-naming PRs merge. This is the lightweight guardrail, NOT the full glossary-generated house-rules system (that is entangled with S1/D7).

Activity

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