Skip to content

feat(control-plane): af install support for Go agent nodes#745

Merged
AbirAbbas merged 2 commits into
mainfrom
feat/installer-go-nodes
Jul 9, 2026
Merged

feat(control-plane): af install support for Go agent nodes#745
AbirAbbas merged 2 commits into
mainfrom
feat/installer-go-nodes

Conversation

@AbirAbbas

Copy link
Copy Markdown
Contributor

Summary

The package installer was hardwired to Python (venv + pip + python -m entrypoints). This adds first-class Go node support:

  • PackageMetadata.Language (go/python) with go.mod detection fallback; additive to config v1 (golden fixture extended per the maintenance contract), Python manifests byte-for-byte unaffected.
  • entrypoint.build compiles the node at install time (go build -o <start> <build>); Go toolchain discovery mirrors pyinterp.go with actionable missing/too-old errors; vendored modules build with -mod=vendor.
  • af run launches the built binary with identical port/healthcheck/secret/env semantics to Python nodes; the service-layer install/start paths route through a shared dispatcher so both code paths stay in lockstep.
  • Out-of-tree replace directives are refused pre-build with vendoring guidance (recommended), plus an AGENTFIELD_GO_REPLACE override for dev installs.
  • Docs: docs/installing-agent-nodes.md gains the Go manifest shape and build model.

Test plan

  • GOFLAGS=-buildvcs=false go build ./..., go vet clean; no new golangci-lint findings in changed files
  • go test ./internal/packages/ ./internal/core/services/ green — new suite covers manifest parse + back-compat, go.mod detection, StartCommand forms (binary / go run / default), build-step via stubbed toolchain, missing/too-old toolchain errors, replace-directive guard (refusal, in-tree, vendored, override), and ValidatePackage with go.mod-only nodes
  • Pre-existing TestDevServiceRunDev port-discovery timeout confirmed identical on untouched HEAD (sandbox-environmental, unrelated)

First consumer: the SWE-AF Go port (Agent-Field/SWE-AF#94), whose agentfield-package.yaml for the Go node builds ./cmd/swe-planner.


🤖 Generated with Claude Code

PackageMetadata gains an explicit language field with go.mod detection
fallback (additive to config v1; Python manifests unchanged).
entrypoint.build compiles the node at install time via a resolved Go
toolchain (pyinterp-style discovery with actionable missing/too-old
errors); af run launches the built binary with identical port,
healthcheck, secret, and env semantics. Out-of-tree replace directives
are refused with vendoring guidance, with an AGENTFIELD_GO_REPLACE
override for dev installs. Service-layer install/start paths route
through the shared dispatcher so both code paths stay in lockstep.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@github-actions

github-actions Bot commented Jul 9, 2026

Copy link
Copy Markdown
Contributor

📊 Coverage gate

Thresholds from .coverage-gate.toml: per-surface ≥ 84%, aggregate ≥ 85%, max per-surface regression ≤ 1.0 pp, max aggregate regression ≤ 0.50 pp.

Surface Current Baseline Δ
control-plane 86.90% 87.40% ↓ -0.50 pp 🟡
sdk-go 91.90% 92.00% ↓ -0.10 pp 🟢
sdk-python 93.76% 93.73% ↑ +0.03 pp 🟢
sdk-typescript 90.42% 90.42% → +0.00 pp 🟢
web-ui 84.76% 84.79% ↓ -0.03 pp 🟡
aggregate 85.55% 85.75% ↓ -0.20 pp 🟡

✅ Gate passed

No surface regressed past the allowed threshold and the aggregate stayed above the floor.

@github-actions

github-actions Bot commented Jul 9, 2026

Copy link
Copy Markdown
Contributor

📐 Patch coverage gate

Threshold: 80% on lines this PR touches vs origin/main (from .coverage-gate.toml:thresholds.min_patch).

Surface Touched lines Patch coverage Status
control-plane 274 83.00%
sdk-go 0 ➖ no changes
sdk-python 0 ➖ no changes
sdk-typescript 0 ➖ no changes
web-ui 0 ➖ no changes

✅ Patch gate passed

Every surface whose lines were touched by this PR has patch coverage at or above the threshold.

@AbirAbbas AbirAbbas marked this pull request as ready for review July 9, 2026 21:26
@AbirAbbas AbirAbbas requested a review from a team as a code owner July 9, 2026 21:26
@AbirAbbas AbirAbbas merged commit 10cfe8a into main Jul 9, 2026
17 checks passed
@AbirAbbas AbirAbbas deleted the feat/installer-go-nodes branch July 9, 2026 21:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant