Skip to content

feat(roadmap): report production readiness in the project review #5537

Done

Description

@dan-petty

Problem or Motivation

The production readiness guideline (docs/guidelines/production-readiness.md) has 90 rows in 10 areas. An agent read the state of each row by hand on 2026-11-13: about 40 reads of git, the GitHub API, kubectl, Argo CD and Prometheus, kept in a scratch file. An agent also counted the baseline files of the 7 repositories of service.repos by hand. No command gives this state again, so the next review repeats the hand work. The owner direction of 2026-11-13: these results come from programs, not from an agent.

Proposed Solution & Architectural Design

Add a readiness section to the project review (devops roadmap review run). Use the reader dispatcher and the Fact model of the fact catalog (#4692), so each value has its source, its query and its read time.

  1. Add a row-check map next to the fact catalog. For each row id of the guideline, it gives the level, the scope (repository or service) and the check. The check kinds: a Scorecard check name, a file on the default branch, a devops command with JSON output, a PromQL query, a field of the service catalog (k8s/CATALOG.md, feat(k8s): generate the service catalog from the rendered Applications #5535), a settings postcondition (feat(gh): manage GitHub organization and repository settings as code #5311), or manual.
  2. The map holds no gap table and no issue number (owner decision of 2026-11-13). Each open gap of the guideline is a sub-issue of the gap tracker issue of SRE and production readiness, so GitHub holds its state, and the map needs no edit when a gap issue closes.
  3. Add a Scorecard reader. It runs the pinned OpenSSF Scorecard binary with --format json for each repository of the live setting service.repos and for the infra repo. It reads the names at run time and writes no name to a file.
  4. Read the files that no Scorecard check reads with the GitHub reader of feat(roadmap): read project review facts through a catalog #4692 and a contents query, not a new reader: AGENTS.md with the route to the shared guidelines (feat(ai): a generated AGENTS.md routes to the shared guidelines #5536), CODEOWNERS, openspec/config.yaml. Scorecard already reads SECURITY.md (Security-Policy), the license (License) and the Renovate config (Dependency-Update-Tool). Row OWN-6 runs devops roadmap onboard --plan, which already checks the job prerequisites.
  5. The report gives each row of each repository and each service one state: met, partly met, not met, does not apply, or not readable. It also gives the source and the read time. The rows of a private repository follow the rule of feat(roadmap): choose the review facts by project profile #4730: they go only to the tracker issue of that repository, never to a shared page. The report is live output: no commit writes its states to git, and the published project review report (feat(roadmap): publish the project review and link it on GitHub #4733) holds the dated copy.
  6. Seed the map from the "Measured by" column of the guideline. Keep no hand state.
  7. --ref <branch> reads the repository rows and the catalog rows at a branch. The launch pull request of a new service posts this output as its readiness record (row EVD-1). An agent writes a state by hand only for a row whose check is manual.
  8. --dry-run makes zero requests and lists the planned reads.

Target Subsystem

SDLC, Git & PR Governance

Existing Tool Considered

  • OpenSSF Scorecard (Apache-2.0, v5.6.0 of 2026-10-12) has 18 checks, such as Branch-Protection, Code-Review, Dependency-Update-Tool, Pinned-Dependencies, Token-Permissions, Security-Policy, SAST, License and Signed-Releases. It covers about 10 practice rows for each repository in any language. Its README does not say that it supports private repositories, so one live run on one private repository comes first.
  • OpenTofu with integrations/github (feat(gh): manage GitHub organization and repository settings as code #5311) gives the settings rows as postconditions and devops tf drift.
  • OpenSSF Allstar (Apache-2.0) is a GitHub App that enforces a few policies. It is one more running service, and it overlaps feat(gh): manage GitHub organization and repository settings as code #5311.
  • todogroup/repolinter is archived, so the rule for maintained dependencies rejects it.

Build only the row-check map and the Scorecard reader. Cost: about 250 lines with tests, about 200k tokens, about 1 agent-day. This item waits for #4692.

Acceptance Criteria

  • A test with a recorded Scorecard JSON of one repository maps the checks to the rows and their states.
  • A test: a row id of the guideline with no map entry fails, and a map entry with no row fails.
  • A test: the check of each map entry names the same tool check or command as the "Measured by" cell of its row, so the guideline and the map cannot drift.
  • A test: no map entry holds an issue number.
  • A test: --ref reads the files of the branch, not of the default branch.
  • A test: the rows of a repository that the GitHub API reports as private are not in the shared report.
  • A test: --dry-run sends no request.
  • A test: the report takes the repository names from settings, and no committed file holds them.
  • One live run on one private repository proves that Scorecard reads it. If it cannot, the practice rows fall back to the GitHub API reads, and the issue records the result.
  • docs/guidelines/production-readiness.md says that the readiness report holds the record of a running service and, with --ref, of a launch.

Alternatives check of 2026-11-23: partly.
Tool: ossf/scorecard (https://github.com/ossf/scorecard), Apache-2.0, last activity 2026-11-23, maintained.
Reason: Searches and the Scorecard README confirm the open, maintained tool with JSON output and 18 checks that map to about 10 repository practice rows; no tool covers the runtime, catalog and command rows.

Covers:

  • Security-Policy, License and Dependency-Update-Tool checks
  • Branch-Protection, Code-Review and Token-Permissions checks
  • Pinned-Dependencies, SAST and Signed-Releases checks with JSON output

Lacks:

  • Runtime checks from kubectl, Argo CD and Prometheus
  • Service catalog fields and devops command JSON results
  • Private repository support unstated, so a live run comes first

Proposed design

Problem statement

The production readiness guideline has 90 rows in 10 areas. devops roadmap review run has no readiness section, so an agent reads each row by hand: about 40 reads of git, the GitHub API, kubectl, Argo CD and Prometheus on 2026-11-13, and a hand count of the baseline files of the seven repositories of service.repos. No command gives this state again, so each review repeats the hand work. The owner direction of 2026-11-13 is that programs give these results, not an agent.

Acceptance criteria

Requirement: The map covers the guideline rows

The row-check map MUST hold exactly one entry for each row id of docs/guidelines/production-readiness.md, with that row's Level and Scope.

Scenario: A missing or an unknown row id

  • WHEN A test parses the row ids, Level cells and Scope cells of docs/guidelines/production-readiness.md and compares them with the row-check map.
  • THEN Each row id has one entry with the same level and scope, and a missing or unknown row id fails the test with its id.

Requirement: The map check matches the Measured by cell

Each row-check map entry MUST name the same tool checks and commands as the Measured by cell of its guideline row.

Scenario: A changed Measured by cell

  • WHEN A test parses each Measured by cell of docs/guidelines/production-readiness.md and compares its tool checks and commands with the entry of the same row id.
  • THEN Each cell matches its entry, and a changed cell fails the test with the row id.

Requirement: The map holds no issue number and no gap table

The row-check map MUST hold no issue number and no gap table.

Scenario: An issue number in the map

  • WHEN A test scans each row-check map entry for an issue reference or a gap table field.
  • THEN No entry holds an issue reference or a gap table field.

Requirement: Scorecard JSON maps to row states

The readiness reader MUST map each Scorecard check in a recorded JSON result to the row that it measures and to that row's state.

Scenario: A recorded Scorecard JSON result

  • WHEN A test gives the reader a recorded Scorecard JSON result of one repository.
  • THEN The report gives each row that a Scorecard check measures a state of met, partly met or not met, and the check name as its source.

Requirement: The Scorecard reader runs the pinned binary

The Scorecard reader MUST run the pinned OpenSSF Scorecard binary with --format json once for each repository of the live setting service.repos and once for each infra repository of the setting infra.repos.

Scenario: Two repositories in settings

  • WHEN A test runs the Scorecard reader with two repositories in service.repos, one repository in infra.repos and a process edge that records the argv.
  • THEN The recorded argv holds one Scorecard run with --format json for each of the two repositories and for the infra repository.

Requirement: File rows use the GitHub contents query

The report MUST read a row whose check is a file on the default branch with the GitHub reader of #4692 and a contents query at the ref.

Scenario: A file row

  • WHEN A test runs the report with a fake GitHub reader for a row whose check is AGENTS.md, CODEOWNERS or openspec/config.yaml.
  • THEN The fake reader receives a contents query for that path at the ref, and the row holds the reader's state, source and read time.

Requirement: Command rows run the devops command

The report MUST run a row whose check is a devops command with its JSON output at the ref and map the JSON result to the row state.

Scenario: A command row

  • WHEN A test runs the report for a row whose check is devops roadmap onboard --plan and a process edge that records the argv and returns a JSON result.
  • THEN The recorded argv holds that command with its JSON output, and the row holds the state of the JSON result, with the command as its source.

Requirement: A manual row gets no request

The report MUST give a row whose check is manual the state not readable and MUST send no request for it.

Scenario: A manual row

  • WHEN A test runs the report for a repository that has a row whose check is manual and a reader that counts requests.
  • THEN The row holds the state not readable and the counter shows no request for it.

Requirement: Each row gives its state, source and read time

The report MUST give each row one state, the source of the value and the time of the read.

Scenario: A readable row

  • WHEN A test runs the readiness report for one repository.
  • THEN Each row holds one state, the source of the value and the read time.

Requirement: The ref option reads the branch

The --ref option MUST read the repository rows at the named branch.

Scenario: A branch differs from the default branch

  • WHEN A test runs the readiness report with --ref at a branch whose files differ from the default branch.
  • THEN The report gives the states of the branch files and not the states of the default branch.

Requirement: Private repository rows stay out of the shared report

The report MUST keep the rows of a private repository out of the shared report.

Scenario: A private repository

  • WHEN A test gives the report a repository that the GitHub API reports as private.
  • THEN The shared report holds no row of that repository.

Requirement: A private repository falls back to the GitHub API

When the pinned Scorecard binary cannot read a private repository, the report MUST read that repository's practice rows with the GitHub API reader of #4692 and name that reader as their source.

Scenario: Scorecard refuses a private repository

  • WHEN A test makes the Scorecard reader fail for a repository that the GitHub API reports as private.
  • THEN The report reads the practice rows with the GitHub API reader and each row names the GitHub reader as its source.

Requirement: The dry run sends no request

The --dry-run option MUST send no request.

Scenario: A dry run with a request counter

  • WHEN A test runs the readiness report with --dry-run and a reader that counts requests.
  • THEN The counter stays at zero and the report lists the planned reads.

Requirement: The report reads the repository names from settings

The report MUST take the repository names from the live setting service.repos at run time.

Scenario: A changed repository list

  • WHEN A test sets service.repos to a list and runs the report.
  • THEN The report reads exactly the repositories of that list, and no committed file of the change holds a repository name of the setting.

Requirement: The guideline states the record use

docs/guidelines/production-readiness.md MUST say that the readiness report holds the record of a running service and, with --ref, of a launch.

Scenario: The readiness record section

  • WHEN A test reads the readiness record section of docs/guidelines/production-readiness.md.
  • THEN It holds a sentence that the readiness report is the record of a running service and, with --ref, of a launch.

Existing Tool Considered

OpenSSF Scorecard (https://github.com/ossf/scorecard) is the open, maintained tool for the repository practice rows. The alternatives check of 2026-11-17 in the issue body gives the verdict partly; its block and comment state what the tool covers and lacks. This change uses Scorecard for the rows it covers and builds the row-check map, the check-kind dispatcher and the devops command reader for the rows it lacks. The file rows reuse the GitHub reader of #4692, and a manual row gets the state not readable. Written cost of the code that the project keeps: about 250 lines with tests, about 200k tokens and about 1 agent-day.

Key questions

  • Which open, maintained tool covers the repository practice rows of the readiness guideline?: OpenSSF Scorecard (https://github.com/ossf/scorecard), Apache-2.0 and maintained. The alternatives check of 2026-11-17 in the issue body gives the verdict partly, and its block and comment state what the tool covers and lacks. The guideline names its checks as SC <check> in the Measured by column. This change uses Scorecard for the rows it covers. (best practice) [sources: docs/guidelines/production-readiness.md]
  • How does the report read the practice rows of a private repository?: The report runs the pinned Scorecard binary first. When the binary fails on a repository that the GitHub API reports as private, the report reads that repository's practice rows with the GitHub API reader of feat(roadmap): read project review facts through a catalog #4692 and names that reader as their source. The fallback makes a live Scorecard run no gate. (best practice) [sources: docs/guidelines/production-readiness.md]
    • Chosen: Scorecard first, GitHub fallback. The Scorecard documentation does not state private repository support, and the fallback keeps the report working when the binary refuses the repository.
    • Rejected: GitHub API only for private repositories. It gives fewer rows than Scorecard when Scorecard does read a private repository.
    • Rejected: Skip private repositories. It leaves the rows of a private repository with no state.
  • Which repositories does the Scorecard reader read besides the repositories of service.repos?: The infra repositories of the setting infra.repos. The setting names each infra repo, its checkout and its agent access level. [sources: CONTEXT.md]
  • Where do the row-check map and the Scorecard reader live?: In a new module src/devops_cli/roadmap/project_review/readiness.py, next to the fact catalog. It uses the Fact model of src/devops_cli/roadmap/project_review/data.py and the reader dispatcher of src/devops_cli/roadmap/project_review/dispatch.py. src/devops_cli/roadmap/project_review/review.py adds the readiness section to the review data. (best practice) [sources: src/devops_cli/roadmap/project_review/data.py:60, src/devops_cli/roadmap/project_review/dispatch.py, src/devops_cli/roadmap/project_review/review.py, src/devops_cli/roadmap/project_review/facts.py]
    • Chosen: A new module next to the fact catalog. The map uses the Fact model and the reader dispatcher, and the review module reads it.
    • Rejected: Inside facts.py. It mixes the 90-row map with the reader code and makes both harder to test.
    • Rejected: A YAML data file. The check kinds hold code and commands, and a data file adds a parser and a schema with no gain.
  • How does the report read a row whose check is a devops command?: The report runs the command of the Measured by cell with its JSON output at the ref, and maps the JSON result to the row state. The command is the source of the value. (best practice) [sources: docs/guidelines/production-readiness.md]
    • Chosen: Run the named command with its JSON output. The guideline already names a repeatable command for each such row, and the report adds no second copy of the check.
    • Rejected: Re-implement each check in the report. It duplicates commands that the repository already keeps and makes the map hold code that no command tests.
  • What does the report give for a row whose check is manual or whose check kind has no reader in this change?: The state not readable, with the check as its source, and no request. A person or an agent writes the state by hand only for a manual row. (best practice) [sources: docs/guidelines/production-readiness.md]
    • Chosen: State not readable with the check as source. The row keeps its place and its source, and the report sends no request for it.
    • Rejected: Omit the row. The report would hide a required row and give it no state.
    • Rejected: Ask a model to read the row. The owner direction of 2026-11-13 is that programs give these results, not an agent.
  • How does the map stay in sync with the guideline?: A test parses each Measured by cell of docs/guidelines/production-readiness.md and compares its tool checks and commands with the map entry of the same row id. A missing row, an unknown row or a different check fails the test and names the row id. (best practice) [sources: docs/guidelines/production-readiness.md]
    • Chosen: A test that parses the table. The table is the source, and a mismatch fails the build with no extra step.
    • Rejected: A generator that writes the map from the table. It adds a build step and a generated file, and the map holds code that the table cannot express.
    • Rejected: Manual review. A person can miss a drift, and the body asks for a test.
  • Does the row-check map hold a gap table or an issue number?: No. Each open gap of the guideline is a sub-issue of the gap tracker issue, so GitHub holds its state and the map needs no edit when a gap issue closes. The guideline itself names no issue. (best practice) [sources: CONTEXT.md, docs/guidelines/production-readiness.md]
    • Chosen: No gap table and no issue number. GitHub holds the state of each gap, and the map needs no edit when a gap issue closes.
    • Rejected: A gap table with issue numbers. The map would need an edit each time a gap issue opens or closes.

Fit

Fits in one pull request.

Suspected block

None.

Dependencies

#4692

Activity

  1. added
    source/agent
    type/feature
    scope/roadmap
    status/new
    value/high
    effort/medium
    on Nov 13, 2026
  2. dan-petty commented on Nov 13, 2026

    @dan-petty
    OwnerAuthor
  3. added
    priority/p2-medium
    on Nov 13, 2026
  4. dan-petty commented on Nov 13, 2026

    @dan-petty
    OwnerAuthor

    The gap tracker of SRE and production readiness is #5541 (owner decision 4 of 2026-11-13). It holds the open gaps of the production readiness guideline as sub-issues and reference lines. The row-check map of this issue names no tracker number and holds no gap table.

  5. devops-cli-service commented on Nov 17, 2026

    @devops-cli-service
    Contributor

    Alternatives check: partly

    Reason: OpenSSF Scorecard is an open, maintained scanner whose 18 repository checks and JSON output cover roughly 10 practice rows per repository, but it says nothing about the runtime, catalog, settings and manual rows the guideline also needs.

    Tool: ossf/scorecard (https://github.com/ossf/scorecard), Apache-2.0, last activity 2026-11-16, maintained.

    Covers:

    • Repository practice rows such as Branch-Protection, Code-Review and Token-Permissions
    • Dependency-Update-Tool, Security-Policy, License and SAST rows
    • Machine-readable JSON output for mapping checks to row states

    Lacks:

    • PromQL runtime rows and service-level checks
    • Settings postconditions and drift, held by the OpenTofu GitHub provider
    • Service catalog fields and file-content rows outside its checks
    • Private repository support is unstated in its documentation
    Searches (6)

    Tools considered:

    Searches run:

    • OpenSSF Scorecard private repositories support, results: 5
    • OpenSSF Scorecard checks list security health metrics, results: 5
    • "Scorecard" OpenSSF GitHub action repository security posture, results: 5
    • scorecard.dev checks Branch-Protection Pinned-Dependencies documentation, results: 5
    • ossf scorecard, results: 5
    • OpenSSF Scorecard open source project security health checks, results: 5

    Sources:

    A person decides what this check of 2026-11-17 means for the item.

  6. devops-cli-service commented on Nov 18, 2026

    @devops-cli-service
    Contributor

    Refine cannot set this item to Ready at 86358b6 while the items below stay open. The next refine round looks at the item again when they close, or when a person replies in a comment or edits the body.

  7. added
    status/ready
    and removed
    status/new
    on Nov 21, 2026
  8. devops-cli-service commented on Nov 21, 2026

    @devops-cli-service
    Contributor

    Next step: the stage job writes the plan of the item. See the section Proposed design of the body.

  9. added
    status/in-progress
    status/in-review
    and removed
    status/ready
    status/in-progress
    on Nov 25, 2026
  10. removed
    status/in-review
    on Nov 25, 2026
  11. devops-cli-service commented on Nov 25, 2026

    @devops-cli-service
    Contributor

    Live since 2026-11-25 17:09 UTC

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

    effort/mediumpriority/p2-mediumscope/roadmapsource/agenttype/featurevalue/high

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions