문제: runner PR 1회(merge job 셋, capacity 1이라 차례로)가 28.5분이다 (run 151). tests job의 FE-GATE-020이 13분 13초로 가장 크고, 그 안의 선택 runtime 제거 드릴 셋(optional recipe, browser file/storage, realtime)이 약 7분이다. worker를 늘리지 않는 대책을 다 넣어도 25분 목표에 닿지 않는다. 고른 방법(소유자 결정 p, 2026-11-12): 그 드릴 셋을 새 게이트 FE-GATE-030 `optional-removability`로 떼어 main 단계(`main_gate`, FE-GATE-029 다음)에서 돌린다. 샘플 제거와 scaffold 드릴은 merge의 FE-GATE-020에 남는다. 짝 백엔드가 무거운 lane을 nightly로 옮긴 것과 같은 모양이다. - 계약: 정규 게이트 ID를 001..030으로, MAIN_READY를 029·030으로, main_gate job의 게이트를 029·030으로 바꾼다. 계약 보고서의 gateCount는 29(016은 은퇴). - scaffold 드릴의 제외 목록에서 셋을 뺀다. 이제 merge 명령이 아니라서, 계약 검사가 「merge 밖 명령을 제외하면 숨긴다」고 거절했다. - main job 이름을 `main / self-tests and removal drills`로 바꾼다. - 시험: 020은 merge·merge_test에서 sample·scaffold만, 030은 main·main_gate에서 셋을 돈다고 단언한다. 승격 공식 시험에 030을 더한다. - 문서: 결정 색인(decisions.md 2.2), 구조·시험·리뷰 기준·CI 문서, fe-structure 스킬의 드릴 명령. 위험·한계: 선택 runtime을 바꾼 PR의 제거 회귀는 병합 뒤 main run에서 본다. main이 빨강이면 다음 PR이 고친다. 그런 PR은 `scripts/verify.sh gate FE-GATE-030`을 직접 돌려야 한다(structure.md 12절에 적음). 파생 프로젝트가 main job 이름을 필수 검사로 걸었으면 이름이 바뀐다. 검증(desktop): generate:ci-workflow, 생성 시험 스냅샷 갱신, ci-workflow-generation·promotion-readiness·feature-scaffold-drill· removal-drill-test-paths·example-feature-rules 등 483개 통과, check:ci(29 gates) rc=0, check:ci:gating rc=0, verify:documentation PASS_SCOPED, check:types·eslint rc=0. 로그 /tmp/claude-gates/w2fe2-o1b~g/.
79 lines
2.8 KiB
TypeScript
79 lines
2.8 KiB
TypeScript
export const PROMOTION_FORMULA = Object.freeze({
|
|
MERGE_READY: Object.freeze([
|
|
"FE-GATE-001",
|
|
"FE-GATE-002",
|
|
"FE-GATE-003",
|
|
"FE-GATE-004",
|
|
"FE-GATE-005",
|
|
"FE-GATE-006",
|
|
"FE-GATE-007",
|
|
"FE-GATE-008",
|
|
"FE-GATE-009",
|
|
"FE-GATE-010",
|
|
"FE-GATE-011",
|
|
// 15-01. Bundle budget: a PR that exceeds it is not merge-ready.
|
|
"FE-GATE-012",
|
|
"FE-GATE-013",
|
|
"FE-GATE-020",
|
|
]),
|
|
RELEASE_READY: Object.freeze([
|
|
"FE-GATE-014",
|
|
"FE-GATE-015",
|
|
"FE-GATE-026",
|
|
// FE-GATE-027. A candidate is only release-ready once it has been admitted
|
|
// to a named environment; coherence alone never proved it belonged there.
|
|
"FE-GATE-027",
|
|
// FE-GATE-028 (08-06). The signed human accessibility review belongs to a
|
|
// release candidate, so it gates release; merge checks the record format.
|
|
"FE-GATE-028",
|
|
]),
|
|
PROD_PROMOTION_READY: Object.freeze([
|
|
// FE-GATE-019 (13-05, D-14). Live hosting headers of the deployed promoted
|
|
// release; the declared-header fixture alone is UNVERIFIED, not PASS.
|
|
"FE-GATE-019",
|
|
// FE-GATE-016 is retired (D-14): it repeated FE-GATE-025's FE-RB-005 drill.
|
|
"FE-GATE-021",
|
|
"FE-GATE-022",
|
|
"FE-GATE-023",
|
|
"FE-GATE-024",
|
|
"FE-GATE-025",
|
|
]),
|
|
FIELD_SLO_READY: Object.freeze(["FE-GATE-018"]),
|
|
DOCUMENTATION_READY: Object.freeze(["FE-GATE-017"]),
|
|
// F2 (design-docs repo-structure/03-ci.md 7.3). The checkers' negative
|
|
// fixtures and the gating coverage check run after a merge to main. They
|
|
// test the checkers, not the change, so they hold no promotion.
|
|
// FE-GATE-030 (owner decision 2026-11-12 p): the optional runtime removal
|
|
// drills moved here from FE-GATE-020. A failure turns main red, and the next
|
|
// pull request fixes it before it merges.
|
|
MAIN_READY: Object.freeze(["FE-GATE-029", "FE-GATE-030"]),
|
|
});
|
|
|
|
export type GateResult = "PASS" | "FAIL" | "UNVERIFIED";
|
|
|
|
export function evaluatePromotionReadiness(
|
|
gateResults: Readonly<Record<string, GateResult>>,
|
|
) {
|
|
const allPass = (gateIds: readonly string[]) =>
|
|
gateIds.every((gateId) => gateResults[gateId] === "PASS");
|
|
|
|
const mergeReady = allPass(PROMOTION_FORMULA.MERGE_READY);
|
|
const releaseReady =
|
|
mergeReady && allPass(PROMOTION_FORMULA.RELEASE_READY);
|
|
const productionReady =
|
|
releaseReady && allPass(PROMOTION_FORMULA.PROD_PROMOTION_READY);
|
|
const fieldReady =
|
|
productionReady && allPass(PROMOTION_FORMULA.FIELD_SLO_READY);
|
|
const documentationReady = allPass(PROMOTION_FORMULA.DOCUMENTATION_READY);
|
|
const mainReady = allPass(PROMOTION_FORMULA.MAIN_READY);
|
|
|
|
return Object.freeze({
|
|
MERGE_READY: mergeReady,
|
|
RELEASE_READY: releaseReady,
|
|
PROD_PROMOTION_READY: productionReady,
|
|
FIELD_SLO_READY: fieldReady,
|
|
DOCUMENTATION_READY: documentationReady,
|
|
MAIN_READY: mainReady,
|
|
});
|
|
}
|