Skip to content

fix(config): name the refused field for a leftover repository broker peer - #3268

Merged
freeqaz merged 2 commits into
mainfrom
fix/config-broker-peer-field
Oct 23, 2026
Merged

freeqaz merged 2 commits into
mainfrom
fix/config-broker-peer-field

Conversation

@freeqaz

@freeqaz freeqaz commented Oct 23, 2026

Copy link
Copy Markdown
Collaborator

Problem

Since #3250, startup refuses an Installation that sets drivers.compute.configuration.network.repositoryCredentials without repository.nativeSender. The refusal was a plain Error, so the API logged only STARTUP_FAILED and the worker only WORKER_STARTUP_FAILED: the startup log keeps no message. Only the chart's upgrade check printed the text, and it runs on upgrade only. A fresh install, or a Secret edit followed by a restart, crash-looped without naming the field. docs/guides/deploy/breaking-changes.md said startup showed the message.

Change

  • installation-config.ts: the refusal is now an InstallationFieldError, the same way fix(egress): name the refused field in an authority block #3260 reports authority-block faults. It has one detail: the pointer /drivers/compute/configuration/network/repositoryCredentials, code INVALID_VALUE and the existing fixed message, which holds no configured values. startupConfigurationFailure maps it to DRIVER_CONFIGURATION_INVALID, so the API's startup-error, the worker's worker.startup-error and the upgrade check all print the field. The upgrade check's line is now installation-check: API and worker startup would refuse the Installation: DRIVER_CONFIGURATION_INVALID: [{"path":"/drivers/compute/configuration/network/repositoryCredentials",...}].
  • configuration-startup.test.mjs: a new test next to fix(egress): name the refused field in an authority block #3260's cases. It boots the real API, worker and check-installation.mjs with a leftover peer and asserts the code and the detail in each. The existing message assertion in the repository refusal table still holds.
  • breaking-changes.md: the 2026-10-23 notice's "How to tell" now names the code and the path the logs show. The page stays under the word limit (2480 by the repo counter; it was 2477).

Verification

  • The new test fails on main (the API diagnostic is STARTUP_FAILED) and passes with the fix.
  • The touched tests (the new one, "repository startup rejects unmatched ...", and "an authority block names each refused field ...") passed 10/10 at 2 CPUs each.
  • tsc --build for the controller, Prettier and ESLint on the touched files: clean.
  • Open PRs touching these files: this branch adds no new conflicted file against any of them (docs: align startup, breaking changes and backend examples with credential proxy #3265 merges cleanly; the others conflict with main already).

Risks

  • Low. The same inputs are refused; only the error class changes. Logs and the upgrade check now carry the field's path and the fixed message, filtered by the existing startup log filter.
  • tests/helpers/egress-installed-resource-cleanup.mjs keeps its 500-then-observe branch. The prepared withdrawal race now answers 409 CREDENTIAL_TOKEN_UNSETTLED, but any other 500 INTERNAL_ERROR from a prepared source delete still reaches that branch, so it is not provably dead.

…peer

A Kubernetes Compute network.repositoryCredentials peer without
repository.nativeSender was refused with a plain Error, so API and worker
startup logged only STARTUP_FAILED / WORKER_STARTUP_FAILED. Throw an
InstallationFieldError with the field's JSON Pointer instead: startup logs
and the chart's upgrade check now report DRIVER_CONFIGURATION_INVALID with
that path and a fixed message. Correct the breaking-changes notice to match.
…er-peer refusal

The upgrade check now prints DRIVER_CONFIGURATION_INVALID with the field's
pointer for a leftover repository broker peer. Update the preflight test's
exact line and let it own the upgrade-check assertion, so the startup test
boots only the API and worker.
@freeqaz
freeqaz requested a review from a team as a code owner October 23, 2026 03:41
@clawsweeper

clawsweeper Bot commented Oct 23, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
ClawSweeper picked this up.

Pull request received. I will update this pull request when review starts.

ClawSweeper review complete

ClawSweeper finished reviewing this revision. The review result is being finalized.

View the workflow run.

@clawsweeper clawsweeper Bot added clawsweeper:intake:bug Preliminary submission classification; full source review pending. clawsweeper:intake:needs-environment Preliminary submission classification; full source review pending. clawsweeper:intake:needs-repro Preliminary submission classification; full source review pending. P2 Normal priority bug or improvement with limited blast radius. rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR. and removed clawsweeper:intake:bug Preliminary submission classification; full source review pending. clawsweeper:intake:needs-environment Preliminary submission classification; full source review pending. clawsweeper:intake:needs-repro Preliminary submission classification; full source review pending. labels Oct 23, 2026
@clawsweeper

clawsweeper Bot commented Oct 23, 2026

Copy link
Copy Markdown
Contributor

Codex review: needs maintainer review before merge.

What this changes

This PR names the leftover repository broker peer in API, worker, and upgrade-check configuration errors.

Example: An Installation retains network.repositoryCredentials on port 8443 after repository.nativeSender is removed.

  • Before: API and worker logs report only STARTUP_FAILED or WORKER_STARTUP_FAILED.
  • After: Logs report DRIVER_CONFIGURATION_INVALID with /drivers/compute/configuration/network/repositoryCredentials and instructions to remove the peer.

Review scores

Measure Result What it means
Overall readiness 🦐 gold shrimp (3/6) The focused patch is source-correct and has meaningful process-level regression coverage; confidence rests on inspected tests, reported runs, and CI rather than independently inspected live output.
Proof confidence 🦐 gold shrimp (3/6) This collaborator-authored PR is outside the ordinary contributor live-proof gate; inspected regression coverage launches the shipped API, worker, and upgrade-check scripts, while the body reports base failure and head success without separate runtime artifacts.
Patch quality 🐚 platinum hermit (4/6) No actionable review findings were identified.

Product

Kind: Bug fix · Worth it: Yes · Fix scope: Complete
User problem: Operators cannot identify the leftover repository peer from API or worker startup logs.
Reason: The collaborator-authored change repairs a concrete diagnostic failure using an existing mechanism, with no new option, permission, or validation rule.

Regression provenance

Regression provenance — verified: source commit 5fe2624fde79 by Free Wortley; canonical PR #3250 (blame-to-merge-commit).

Merge readiness

✅ Ready for maintainer review

Keep this PR open: it fixes a current-main diagnostic gap with a focused change, and no actionable correctness or security defect was found.

Priority: P2
Reviewed head: e28eb8a619b9ab2fa2518b371a6f52ca850b2bbd

Before merge

None.

Findings

None.

Agent review details

How this fits together

Installation composition validates operator configuration before API and worker startup; shared error formatting sends refused-field details to startup logs and the Helm upgrade check.

flowchart TB
  A[Installation configuration] --> B[Installation loader]
  B --> C[Repository peer validation]
  C --> D[Installation field error]
  D --> E[Shared diagnostic formatter]
  E --> F[API and worker logs]
  E --> G[Helm upgrade check]
Loading

Technical review

Best possible solution:

Use the existing field-error owner to report the refused peer while preserving validation and peer-removal recovery.

Do we have a high-confidence way to reproduce the issue?

Current-main source shows that a Kubernetes Installation with the peer and no native sender throws a plain Error, which API and worker startup reduce to generic codes; no target code was executed during this review.

Is this the best way to solve the issue?

The patch uses the established shared diagnostic mechanism and preserves the original refusal, making it the smallest complete repair for the stated problem.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning medium; reviewed against 92caa7ac6250.

Provenance checked

Testing

Proof path: in-process harness.

Security

None.

Evidence

What I checked:

Likely related people:

  • Free Wortley: Raw commit 5fe2624 adds apps/controller/src/composition/installation-config.ts:876 relative to its recorded parents. This identifies author metadata, not feature responsibility or a PR merger. (role: source-line author; confidence: high; commits: 5fe2624fde79; files: apps/controller/src/composition/installation-config.ts)

Labels

Label changes:

  • add P2: This improves diagnosis and recovery for an advanced operator configuration failure without changing which Installations can start.
  • add rating: 🦐 gold shrimp: Overall readiness is 🦐 gold shrimp; proof is 🦐 gold shrimp and patch quality is 🐚 platinum hermit.
  • add status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR.

Label justifications:

  • P2: This improves diagnosis and recovery for an advanced operator configuration failure without changing which Installations can start.
  • rating: 🦐 gold shrimp: Overall readiness is 🦐 gold shrimp; proof is 🦐 gold shrimp and patch quality is 🐚 platinum hermit.
  • status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR.

Rating scale

6/6 🦀 challenger crab · 5/6 🦞 diamond lobster · 4/6 🐚 platinum hermit · 3/6 🦐 gold shrimp · 2/6 🦪 silver shellfish · 1/6 🧂 unranked krab. Overall follows the weaker of proof and patch quality; ✨ marks media proof (a screenshot, video, or linked artifact) that directly shows the changed behavior.

Workflow

ClawSweeper edits this one comment on every review. Comment @clawsweeper re-review for a fresh review only. Repair and merge execution lanes are retired.

Reviewed October 22, 2026, 11:54 PM ET / October 23, 2026, 03:54 UTC.

@freeqaz
freeqaz merged commit da921f0 into main Oct 23, 2026
76 checks passed
@freeqaz
freeqaz deleted the fix/config-broker-peer-field branch October 23, 2026 03:57
freeqaz added a commit that referenced this pull request Oct 23, 2026
Internal review nits: the replaced table case used a port below 8443, so
keep that setup; compare the booted processes' full detail as #3268's
test does; pin the endpoint REQUIRED wording.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

P2 Normal priority bug or improvement with limited blast radius. rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant