Org policy file: devready check --policy FILE

Aperta
#44 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
5/5
Tempo stimato
Più di una settimana
Idoneità per principianti
45/100
Tipo di issue
Funzionalità
Chiarezza
Abbastanza chiara
Stato di attività
Attiva
Stack tecnologico
python
Ambito
cli, devtools

Direzione di ricerca

Start with section 6 of docs/plans/features-5-8.md and the existing check_tool version checks and _compare logic; the issue recommends beginning after #43. The plan spans policy loading and validation, evaluation, CLI and environment options, GitHub Action support, starter file generation, and documentation. Follow its one PR per step sequence; done means the stated policy results and exit behavior work, invalid content produces one policy.file ERROR without echoing contents, and organization guidance is documented.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

enhancement

Problem: Platform teams want one minimum toolchain for every repo ("Git >= 2.40, Node >= 20, Docker required") without editing each repo's .devready.json, whose keys are frozen in 1.x.

Do: follow section 6 of the team features plan. One PR per step:

  • checks/policy.py: loader and validator, with hostile-content tests (file content is never echoed).
  • Requirement evaluation reusing check_tool versions and _compare; policy.* ids, explain.py entries, docs/checks.md rows.
  • --policy FILE flag and DEVREADY_POLICY env var; works with --recursive (#43), applying to every package.
  • GitHub Action policy input; devready init --policy prints a starter file.
  • Docs: a "Using DevReady across an organization" guide.

Policy file shape (unknown keys make the file invalid, reported as one ERROR result):

{"policy_version": 1,
 "require": {"node": ">=20", "python": ">=3.11", "git": ">=2.40", "docker": "*"},
 "skip": ["platform.autocrlf"],
 "env": ["NPM_TOKEN"]}

Done when:

  • devready check --policy org.json reports policy.<tool>.require results, and a policy fail exits 1.
  • A repo's .devready.json skip cannot skip policy.* ids.
  • An invalid policy file gives one policy.file ERROR and never prints its contents.

Notes:

  • Local files only. Remote URLs stay out (network checks need a design review first, see ROADMAP.md); teams vendor the file or fetch it in CI.
  • DEVREADY_POLICY holds a path; its value is never printed.
  • Best started after #43.
Lingua principale
Python
Stelle
2
Fork
3
Merge medio
10h 51m
PR unite (30g)
40

Preparare l'ambiente

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di Evalogical-Inc/devReady

Tutte le issue di Evalogical-Inc/devReady

Issue simili

Altre issue su Python

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.