repo_policy_sync: distinguish absent GitHub refs from compliant refs
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
Direzione di ricerca
Start by tracing the ensure_exact and ensure_minimal operations through the policy runner, including the existing when.file_contains condition. Verify how absent, matching, and outdated GitHub action or reusable-workflow references are currently mapped. Done means the status distinguishes not-applicable, compliant, and changes-required while preserving a separate way to require a reference.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Problem
Policies using ensure_exact or ensure_minimal for external GitHub action or reusable-workflow references are currently applicable to every synchronized repository. If a repository has no matching uses: reference, the operation produces no changes and the runner reports compliant.
This makes the report unable to distinguish a repository that uses the target at the required revision from one that does not use the target at all. Policy authors currently need to duplicate the target in a when.file_contains condition to avoid the misleading status.
Desired behavior
Provide operation-aware applicability, or an equivalent policy condition, so that:
- no matching target reference is
not-applicable; - a matching reference at the required revision is
compliant; - a matching outdated reference is
changes-required; and - policy authors do not need to duplicate the target in a regex condition.
The design should preserve a way for a separate policy to require that a reference exists, if that is needed.
First solution idea (initial proposal, not final design)
Let reference operations report whether they are applicable based on whether their target is present:
ensure_exactandensure_minimalalready know the target repository, workflow path, and reference they inspect.- If no matching
uses:entry exists, the operation could returnapplicable: false, which the runner maps tonot-applicableinstead of treating the absence of changes ascompliant. - If a matching entry exists, the existing result mapping remains unchanged: the required reference is
compliant, while an outdated reference ischanges-required. - An explicit presence assertion or condition can remain available for policies whose purpose is to require that a reference exists.
The exact API and whether this behavior should be opt-in (for example, through an operation setting) still need discussion. The important part of this first idea is to derive applicability from the reference operation itself, avoiding duplicated target strings in policy conditions and generalizing to other reference-based operations.
- Lingua principale
- Python
- Stelle
- 1
- Fork
- 5
- Merge medio
- 23h 38m
- PR unite (30g)
- 13
Preparare l'ambiente
- Nessun Dockerfile né file Docker Compose
- Nessun modello di pull request
- Leggi la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di eclipse-score/tools
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
eclipse-score/tools#82 ·
I maintainer di solito rispondono entro 1 giorno
-
setup up conventional PRsApertadiscussion required good first issue
Difficoltà 2/5 1-3 ore Idoneità per principianti 67/100
eclipse-score/tools#8 ·
I maintainer di solito rispondono entro 1 giorno
-
good first issue
Difficoltà 4/5 3-5 giorni Idoneità per principianti 45/100
eclipse-score/tools#55 ·
I maintainer di solito rispondono entro 1 giorno
-
repo-policy-sync
Difficoltà 4/5 3-5 giorni Idoneità per principianti 48/100
eclipse-score/tools#31 ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 4/5 3-5 giorni Idoneità per principianti 68/100
eclipse-score/tools#28 ·
I maintainer di solito rispondono entro 1 giorno
Tutte le issue di eclipse-score/tools
Issue simili
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 62/100
NL-BioImaging/biomero#136 ·
I maintainer di solito rispondono entro 1 giorno
-
Grayscale PNGs with partial transparency can turn gray pixels whiteForse già presa @ktz03 l’ha presa oggi. Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
-
Add deterministic regex redaction for IDs, IBANs, and account numbers in summaries & keywordsApertaenhancement good first issue help wanted
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
floorianmb/tidywise#5 ·
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 70/100
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 85/100
TigreGotico/phoonnx#1115 ·
I maintainer di solito rispondono entro 1 giorno