Skip to content

refactor(github): remove the board sync and reconcile commands #5291

Done

Description

@dan-petty

Problem or Motivation

Child 21 of the ADR modernization (#5233). Code after owner decision 5.

The review of each record that this item changes:

  • ADR 0016 (supersede (merge with 0001 into the roadmap-state record)): Labels and the single PATCH hold. The issue-field rejection has been false since 2026-11-11, so it becomes 'deferred until a spike'. The lock in one process does not cover all writers (cite 0021 rules 2-4). The board commands wait for owner decision 5.

Proposed Solution & Architectural Design

Delete devops gh project sync and reconcile, .github/project-template.json and the docs/ROUTINE_TASKS.md:55 row. Keep project_read.py only if another command uses it.

Owner decision 5 of 2026-11-12: Delete devops gh project sync, reconcile, .github/project-template.json and the ROUTINE_TASKS row. The built-in board workflows keep the cards.

Rules of the ADR process (docs/adr/README.md, #5225) that apply:

  • Use one form for a Status History line, 30 words at most: 'YYYY-MM-DD: Amended by ADR NNNN, section S | Amended by the owner decision in #N, section S | Superseded by ADR NNNN | Fact out of date: (#N) | Living detail moved to (#PR).' The PR that makes a fact of a record wrong adds the line (AGENTS.md rule 8). An agent never edits the body of an accepted record.

Keep these constraints on purpose. The review found a reason for each one:

  • ADR 0016, one PATCH for a label family and its job record: with two requests, a field can lose its record, and the guard then reads the job's own write as a person's change.
  • ADR 0002/0016, a job never reverts a person's change: 9 guard stops in 7 days. The rule moves to the roadmap-state record and stays in force.

Target Subsystem

src/devops_cli/commands/gh/, .github/project-template.json, docs/ROUTINE_TASKS.md.

Existing Tool Considered

The built-in GitHub Projects workflows (Item closed, Pull request merged, auto-add by filter) keep the cards.

Acceptance Criteria

  • devops gh project sync and reconcile, .github/project-template.json and the row at docs/ROUTINE_TASKS.md:55 go.
  • project_read.py stays only if another command uses it. The pull request names the users, or removes the module.
  • devops gh project --help lists no sync or reconcile, and no document names them.

Dependencies

Owner decision 5 of 2026-11-12 is made. The roadmap-state record of #5235 names the board commands.

Related

Source: #5233

Alternatives check of 2026-11-16: not-applicable.
Class: refactor, no search.
Tool: none found.

Proposed design

Problem statement

The devops gh project group still holds sync and reconcile commands that write a project board. ADR 0042 holds the roadmap state in issues, labels and body records, and no roadmap job reads or writes a board. The commands are dead weight, and their help text and routine row still name them. This change removes the two subcommands, their code, strings and tests, and the routine-task row. The template stays because the kept audit and views commands load it, and its deletion moves to a follow-up issue.

Acceptance criteria

Requirement: The board commands are removed

The devops gh project group SHALL list no sync subcommand and no reconcile subcommand.

Scenario: The project group help

  • WHEN uv run devops gh project --help runs.
  • THEN The command exits 0 and its output holds no sync line and no reconcile line.

Requirement: The board writer functions are removed

src/devops_cli/github/projects.py MUST hold no sync_remote_project function and no reconcile function.

Scenario: The board writer functions are absent

  • WHEN uv run pytest tests/github/test_github_projects.py::test_board_writers_removed -q runs.
  • THEN The test passes.

Requirement: The command module registers no board writer

src/devops_cli/commands/gh.py MUST hold no call to sync_remote_project or to a reconcile function.

Scenario: The command module test

  • WHEN uv run pytest tests/commands/test_gh_cmd.py::test_gh_project_has_no_sync_or_reconcile -q runs.
  • THEN The test passes.

Requirement: The help text names no removed command

src/devops_cli/lang/en/help.py MUST hold no line that names devops gh project sync or devops gh project reconcile.

Scenario: The help text

  • WHEN uv run pytest tests/commands/test_gh_cmd.py::test_help_has_no_board_sync_or_reconcile -q runs.
  • THEN The test passes.

Requirement: The routine task row is removed

docs/ROUTINE_TASKS.md SHALL hold no row that starts | **Workspace & Sync**.

Scenario: The routine task row

  • WHEN git grep -n -F '| **Workspace & Sync**' -- docs/ROUTINE_TASKS.md runs.
  • THEN The command prints no line and exits 1.

Requirement: The command reference is current

docs/CLI_REFERENCE.md MUST be the output of its generator after the deletion.

Scenario: The docs check

  • WHEN uv run devops ci --check --only docs runs.
  • THEN The check exits 0.

Requirement: The read module keeps its importer

src/devops_cli/github/project_read.py MUST stay while src/devops_cli/github/projects.py imports it.

Scenario: The read module importer

  • WHEN git grep -q 'devops_cli.github.project_read' -- src/devops_cli/github/projects.py runs.
  • THEN The command exits 0.

Requirement: The template stays for the kept commands

.github/project-template.json MUST stay while the audit and views commands load it.

Scenario: The kept commands load the template

  • WHEN uv run pytest tests/github/test_gh_project_views_pages_dry_run.py tests/commands/test_gh_cmd.py -q runs.
  • THEN The tests pass.

Existing Tool Considered

The alternatives check of 2026-11-16 in the issue body records not-applicable for a refactor class and names no tool. No open, maintained tool covers the removal of the project's own commands. The built-in GitHub Projects workflows keep the cards with no code of ours. The change adds no code that the project keeps, so it has no build cost.

Key questions

  • Does .github/project-template.json stay, or do the audit and views commands go?: The template stays in this change. load_project_template() at src/devops_cli/github/projects.py:142 reads it, and the kept status, audit, show-template and views commands call it with no --template argument. The deletion of the template and the fate of those commands move to a follow-up issue. (best practice) [sources: src/devops_cli/github/projects.py:142, src/devops_cli/commands/gh.py:571, tests/github/test_gh_project_views_pages_dry_run.py:38]
    • Chosen: Keep the template for this change. The kept audit and views commands load it with no --template argument, so a deletion breaks them.
    • Rejected: Delete the template and remove the audit and views commands. This expands the change past the sync and reconcile commands and needs a decision on each kept command.
    • Rejected: Delete the template and rewrite the commands to read no template. This needs a new read path and new tests, so it is a separate design.
  • Which code and tests go with devops gh project sync and reconcile?: Remove the subcommand registrations in src/devops_cli/commands/gh.py, the sync_remote_project function at src/devops_cli/github/projects.py:1449, the reconcile functions at src/devops_cli/github/projects.py:1355 and :1485, the strings in src/devops_cli/lang/en/help.py and src/devops_cli/lang/en/messages.py, and the tests that call them, such as tests/github/test_github_projects_reconcile.py and the sync tests of tests/commands/test_gh_cmd.py. [sources: src/devops_cli/commands/gh.py, src/devops_cli/github/projects.py:1355, src/devops_cli/github/projects.py:1449, src/devops_cli/github/projects.py:1485, src/devops_cli/lang/en/help.py, src/devops_cli/lang/en/messages.py, tests/github/test_github_projects_reconcile.py, tests/commands/test_gh_cmd.py]
  • Does src/devops_cli/github/project_read.py stay?: It stays. src/devops_cli/github/projects.py imports devops_cli.github.project_read, and the kept audit and views commands use projects.py. The pull request keeps the module and tests/github/test_github_project_read.py. [sources: src/devops_cli/github/projects.py, tests/github/test_github_project_read.py]
  • Does the whole row at docs/ROUTINE_TASKS.md:55 go?: Yes. Owner decision 5 of 2026-11-12 names the row, and the row names the removed devops gh project sync. The row goes. The audit commands keep their generated entries in docs/CLI_REFERENCE.md. (best practice) [sources: docs/ROUTINE_TASKS.md, docs/CLI_REFERENCE.md]
    • Chosen: Delete the whole row. Owner decision 5 names the row, and the row names the removed sync command.
    • Rejected: Rewrite the row to keep the audit commands. The owner decision names the row, so a rewrite contradicts it.
  • Does this change edit ADR 0016?: No. ADR 0016 is superseded by ADR 0042, and docs/adr/README.md says do not amend a superseded record. This pull request adds no Status History line to ADR 0016. (best practice) [sources: docs/adr/README.md, docs/adr/0016-labels-hold-the-roadmap-items-fields.md, docs/adr/0042-issues-labels-and-body-records-hold-roadmap-state.md]
    • Chosen: Add no line and change no body text. ADR 0042 supersedes ADR 0016, and the ADR process forbids an amendment of a superseded record.
    • Rejected: Add a Status History line to ADR 0016. The record is superseded, so the line belongs in the record in force.
    • Rejected: Edit the body of ADR 0016 in place. The ADR process forbids a body edit, and the body-hash test fails on it.
  • Which documents name the removed commands?: The row at docs/ROUTINE_TASKS.md:55, the generated command reference docs/CLI_REFERENCE.md, and the help strings in src/devops_cli/lang/en/help.py. The change updates each one in the same pull request. [sources: docs/ROUTINE_TASKS.md, docs/CLI_REFERENCE.md, src/devops_cli/lang/en/help.py]
  • Does sync_remote_project go from src/devops_cli/github/projects.py?: Yes. sync_remote_project is defined at src/devops_cli/github/projects.py:1449, and src/devops_cli/commands/gh.py calls it. The change removes the function and its caller. [sources: src/devops_cli/github/projects.py:1449, src/devops_cli/commands/gh.py]
  • Does the reconcile code go from src/devops_cli/github/projects.py?: Yes. The reconcile functions are defined at src/devops_cli/github/projects.py:1355 and src/devops_cli/github/projects.py:1485, and src/devops_cli/commands/gh.py calls them. The change removes the functions and their caller. [sources: src/devops_cli/github/projects.py:1355, src/devops_cli/github/projects.py:1485, src/devops_cli/commands/gh.py]

Fit

Fits in one pull request.

Suspected block

None.

Dependencies

#5235

Moved to new items

#7803

Activity

  1. added
    source/agent
    on Nov 13, 2026
  2. added
    type/refactor
    scope/github
    status/new
    value/medium
    effort/medium
    on Nov 13, 2026
  3. dan-petty commented on Nov 13, 2026

    @dan-petty
    OwnerAuthor
  4. added
    priority/p2-medium
    on Nov 13, 2026
  5. devops-cli-service commented on Nov 16, 2026

    @devops-cli-service
    Contributor

    Alternatives check: not-applicable

    Class: refactor. The check makes no search and no model call for an item of this class.

    Tool: none found

    Checked on 2026-11-16. A person decides what this means for the item. The check changes no label and closes no issue.

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

    @devops-cli-service
    Contributor

    Refine cannot set this item to Ready at 73743a2 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. devops-cli-service commented on Nov 27, 2026

    @devops-cli-service
    Contributor

    Next step: the open items close, or a person replies in a comment or edits the body. See Dependencies and Watched files in the section Proposed design of the body.

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

    @devops-cli-service
    Contributor

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

  10. dan-petty commented on Nov 29, 2026

    @dan-petty
    OwnerAuthor

    Returned under AGENTS.md rule 2: cannot delete .github/project-template.json as specified while keeping the remaining board/view commands working. Acceptance requires deleting .github/project-template.json and states that devops gh project audit and devops gh views audit stay. However, load_project_template() (src/devops_cli/github/projects.py:142-153) defaults to CONST_PROJECT_TEMPLATE_PATH (.github/project-template.json) and raises GitHubOperationError when absent. Every kept command in src/devops_cli/commands/gh.py calls load_project_template(template_file): status_project (line 571), _resolve_project_number (line 640), audit_project (line 879), show_template (line 912), list_views (line 930), spec_views (line 954), sync_views (line 1003), and audit_views (line 1045), and tests/github/test_gh_project_views_pages_dry_run.py:38-53 plus tests/commands/test_gh_cmd.py:40 invoke them without --template. Refinement must decide whether .github/project-template.json stays for the kept audit/views commands or those commands are removed or rewritten.

  11. added
    status/new
    and removed
    status/ready
    on Nov 29, 2026
  12. added
    status/ready
    and removed
    status/new
    on Nov 29, 2026
  13. devops-cli-service commented on Nov 29, 2026

    @devops-cli-service
    Contributor

    Next step: the stage job writes the plan of the item. See Moved to new items in the section Proposed design of the body.

  14. added
    status/in-progress
    status/in-review
    and removed
    status/ready
    status/in-progress
    on Nov 29, 2026
  15. removed
    status/in-review
    on Nov 29, 2026
  16. devops-cli-service commented on Nov 29, 2026

    @devops-cli-service
    Contributor

    Live since 2026-11-29 22: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/githubsource/agenttype/refactorvalue/medium

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions