Skip to content

fix(roadmap): fix-conflict runs its fixers only in a runner Job - #6620

Merged
dan-petty merged 9 commits into
mainfrom
fix/6618-fix-conflict-runner-only
Nov 21, 2026
Merged

dan-petty merged 9 commits into
mainfrom
fix/6618-fix-conflict-runner-only

Conversation

@dan-petty

@dan-petty dan-petty commented Nov 21, 2026 •

Copy link
Copy Markdown
Owner

devops roadmap step fix-conflict runs tier 1 only in a runner Job, with plain git.

  • --confirm needs a runner Job (require_runner, deny_environment_reads, adopt_orphans). Without it, the step returns planned and runs no code of the pull request.
  • The step clones into a new folder of the run, switches to the head branch, and pushes through OriginGit to the URL read before tier 1, with a lease on the judged head.
  • Tier 1 settles each stop as a developer does: git rebase --skip for the archive commit of the item, then it archives again; main's side for generated documents and uv.lock. Another conflict stops the round.
  • Each round runs in one function. A round that does not end resolved aborts, gives the branch back its tip and counts. It never pushes the tip of main.
  • The plan and the round share one rule.
  • The unused roadmap.fix_conflict.tier2_mode goes.

Closes #6618

Change: openspec/changes/archive/2026-11-21-6618-fix-conflict-runner-only/

@dan-petty dan-petty added type/bug Type bug: the code does not do what it must scope/roadmap The roadmap jobs: intake, refine, stage, implement and the Service that runs them labels Nov 21, 2026
@dan-petty
dan-petty force-pushed the fix/6618-fix-conflict-runner-only branch from 16e61c8 to 90f36f8 Compare November 21, 2026 13:11
@devops-cli-service

Copy link
Copy Markdown
Contributor

Pull request #6620 has merge conflicts with main at commit 90f36f86d6e7. GitHub cannot merge it. Rebase the branch onto the current main, resolve the conflicts and push the branch.

@dan-petty
dan-petty force-pushed the fix/6618-fix-conflict-runner-only branch 2 times, most recently from 08b6908 to 18e1e27 Compare November 21, 2026 18:39
@dan-petty
dan-petty marked this pull request as ready for review November 21, 2026 18:40
Tier 1 of `devops roadmap step fix-conflict` runs `devops docs generate`
and `uv lock`, which run code of the checkout of the pull request.

- `--confirm` runs only in a runner Job: the command calls
  `require_runner`, `deny_environment_reads` and `adopt_orphans` first.
  Without `--confirm` the step returns `planned` and runs no code of the
  checkout, pushes nothing and writes no record.
- The step reads the URL of `origin` after its clone, and fetches and
  pushes through `OriginGit` with a lease on the judged head.
- Each git call of the step runs with `core.hooksPath=/dev/null`.
- The checkout of the head branch works in the shallow clone, and
  `git rebase --continue` takes `-c core.editor=true` with no
  environment override.

Closes #6618

Change: `openspec/changes/archive/2026-11-21-6618-fix-conflict-runner-only/`
- A rebase that fails with no conflicted file stops the round. Before
  a push the step checks that HEAD is the head branch, holds the tip of
  the default branch and differs from it, and holds each change of the
  pull request, so it never pushes the tip of the default branch.
- The clone of the step commits as the bot (`commit_author`, as
  `ensure_checkout` does).
- The step deepens its shallow clone through `OriginGit` until it holds
  the merge base, and fails with a clear reason when the history holds
  none. `OriginGit.fetch` takes `deepen`, and a fetch that makes the
  history whole removes the `shallow` file of the clone.
- The plan names what a confirmed round does.
- `OriginGit` writes the refs of the clone with the hooks of the clone
  off.
- The unused setting `roadmap.fix_conflict.tier2_mode` goes.

Refs #6618
- The step clones into a new folder of the run (`ensure_checkout`),
  switches to the head branch, and needs no fetch. The depth-50 clone,
  the deepening and the content check before the push go.
- Tier 1 settles each stop of the rebase: `git rebase --skip` for an
  archive commit that holds only OpenSpec paths and generated documents,
  then a new archive commit; the default branch for generated documents
  and `uv.lock`.
- The guard before the push is a commit past the default branch.
- The plan and the round use one release check. The authors come from
  `person_authors`; the conflicted paths from `git merge-tree
  --name-only`.
- A failed round of the implement job gives the branch back its tip.
- The hooks switch of the local git calls and of `OriginGit` goes.

Refs #6618
- At a stop, tier 1 first takes main for generated documents and
  uv.lock: `git checkout --ours`, or `git rm` for a file that main
  deleted.
- It drops only the archive commit of the item, the commit that moves
  its change folder into the archive. Another conflicting OpenSpec
  commit stops the round.
- A git call that fails ends the round as a recorded stop: the rebase
  is aborted, and the implement branch gets back its tip.
- Only `openspec validate --specs --strict` runs before the push; the
  docstring, the spec and ADR 0021 now say so.

Refs #6618
- `_round` runs a round for the step and for the implement job: the
  rebase, its stops, the regeneration, the validation and the push. Its
  `finally` aborts the rebase and gives the branch back its tip when the
  round does not end resolved, for any error, and records the round
  with the rounds plus one.
- Each `--skip` or `--continue` moves the rebase on, or the round stops.
- Tier 1 takes main's side by the stages of the index: `git rm` with no
  stage 2, else `git checkout --ours`.
- The plan and the round use one classification of the conflicted paths.
- The archive commit of the item touches no other change.
- The implement job aborts the rebase only while one is in progress.

Refs #6618
With the settings scan gone (#6646), a setting that tier 1 writes into the clone changes no push in a runner Job either. The test of the push runs with roadmap.implement.in_runner true, and the scenario names the runner Job.

Refs #6618
A timeout or another error of the round of tier 1 in the rebase of the implement job now stops the item with no push, with the class timeout for a timeout. The round has already given the branch back its tip and recorded itself; a push would rebase again and run tier 1 a second time. The warning of an unsettled round logs its result value.

Refs #6618
The stop of _rebase for an error of the round of tier 1 lets AICredentialsError, GitHubUnauthenticatedError and ServiceStoppingError out of the job, as the other sites of the job do, so a one-time failure does not Block the item.

Refs #6618
The test of the errors that leave the round of tier 1 patches the record write of the store with monkeypatch, so it adds no type suppression.

Refs #6618
@dan-petty
dan-petty force-pushed the fix/6618-fix-conflict-runner-only branch from 18e1e27 to a0ebe22 Compare November 21, 2026 19:01
@dan-petty
dan-petty merged commit fe2f2e8 into main Nov 21, 2026
32 checks passed
@dan-petty
dan-petty deleted the fix/6618-fix-conflict-runner-only branch November 21, 2026 19:15
dan-petty-release Bot added a commit that referenced this pull request Nov 21, 2026
🤖 I have created a release *beep* *boop*
---


##
[0.188.4](v0.188.3...v0.188.4)
(2026-11-21)


### Bug Fixes

* **k8s:** cap Tempo query limits under its memory limit
([#6669](#6669))
([62f16d5](62f16d5))
* **roadmap:** fix-conflict runs its fixers only in a runner Job
([#6620](#6620))
([fe2f2e8](fe2f2e8))


### Code Refactoring

* **git:** git uses the configured credential helper
([#6663](#6663))
([c0957ae](c0957ae))

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).

Co-authored-by: dan-petty-release[bot] <346998822+dan-petty-release[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

scope/roadmap The roadmap jobs: intake, refine, stage, implement and the Service that runs them type/bug Type bug: the code does not do what it must

Projects

None yet

Development

Successfully merging this pull request may close these issues.

fix(roadmap): fix-conflict runs its fixers only in a runner Job

2 participants