Repository navigation
chore(agents): go-grpc 0.1.72, so a process receives each configuration variable once - #1287
Conversation
…on variable once go-grpc 0.1.58 put a native service's environment on the runner environment and handed it to the process again, so every configuration variable arrived twice; platform-core's gate refused saas/accounts with a 992,926-byte environment. go-grpc 0.1.72 (service-go-grpc#220) delivers it once. `codefly update workspace` moved accounts and auth-gateway to 0.1.72. It also moved nextjs and postgres; those moves are left for their own change. 0.1.72's Sync keeps a custom-adapter service's marked main.go current and renders plugins/registry_gen.go from plugins/plugins.yaml only with the full scaffold. Accounts has no single AccountsService, so 0.1.58 never touched either file, and both are hand-maintained (main serves the module authority listener and finishes work wiring before any listener opens). Say so: main.go drops the generated-code marker, the registry becomes plugins/registry.go, and the plugins.yaml no agent ever read (it used `import:`) is deleted. Sync is now clean for both services. Runnables regenerated: the three accounts runnable packages record the agent version, so their digests move. Contracts and generated libraries unchanged. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
go-grpc 0.1.72 builds on golang:1.27.3-alpine3.23@sha256:8a504649 and runs on alpine:3.23.7@sha256:ff7f0c72 (its build_images.go and AlpineDigest; 3.23.7 carries the OpenSSL 3.5.9 and musl 1.2.5-r24 fixes 3.23.5 lacked). The build-evidence gate refused accounts and auth-gateway on the old expectation, so the image contract moves with the agent, as RELEASE_GATES.md requires. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
… advisories The supply-chain job's `npm audit --omit=dev --audit-level=high` on the frontend failed on follow-redirects 1.16.1 (GHSA-mrwp-f3q8-3g9p, high; fixed in 1.16.2) and reported fast-uri 3.1.8 (GHSA-w74x-v6f9-j3xg, GHSA-wjr9-j795-jxcr, GHSA-xhq7-xmqj-769h, GHSA-333x-w4r6-6crp; fixed in 3.1.9). follow-redirects moves in the lockfile only, inside axios's ^1.16.0. fast-uri moves through the override that already pinned it, now `<3.1.9 -> 3.1.9`. Nothing else in the lockfile changed. deepmerge 4.3.1 (GHSA-gcqx-w48m-w2h4, low, via swagger-client) has no patched release; it stays, below the job's high threshold. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
…try as stopgaps The accounts main.go and plugins/registry.go should be go-grpc's generated output. They stay hand-maintained only because the agent cannot generate them for a multi-service, custom-adapter service: its main-only refresh drops the module authority listener and starts the server before work's wiring, and it renders no registry without a single AccountsService. Both files now say so and name codefly-dev/service-go-grpc#223, the request for that shape. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
module-saas-starter#1287 review, head 4ce393e (bug-hunter + security)No blockers found. Ran locally: Follow-ups, ranked
Verified clean
VERDICT: merge |
…not registry_gen.go Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Move authority-core, authority-client and the conformance suite from d0210535 (#62) to authority main dea37afa (#65). The suite at the old pin raced a one-second delegation against its parent session's whole-second expiry ("a standing one-second delegation does not issue ... parent session expired") and reddened the pinned conformance job; #65 fixes that case, and the authority-main job already ran it. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Why
platform-core's gate refused to start
saas/accountsnatively because its environment was 992,926 bytes, with each key counted twice (service-go-grpc#220). I could not find the accounts log line itself on any issue. The same refusal from a sibling agent is quoted verbatim in service-go#162:(The list of keys is cut: the same key appears twice in it.)
The cause is go-grpc 0.1.58:
CreateRunnerEnvironmentput the service's whole environment on the runner environment, andStarthanded the same set to the process again.The agent fix
go-grpc 0.1.72 carries service-go-grpc#220 ("hand the service its environment once"). The runner environment no longer carries the service environment, so
Startdelivers each variable once. It still builds with Go 1.27.3 (GoVersion = "1.27.3"), so the AGENTS.md toolchain line only changes its version.What moved / regenerated
codefly update workspace(CLI v0.1.233, checksum checked): accounts and auth-gateway go from 0.1.58 to 0.1.72. The command also moved nextjs (0.0.167 to 0.0.171) and postgres (0.0.146 to 0.0.147). I reverted those two so this PR stays on one objective; they can move in their own PR.Runtime image change, disclosed. Agent 0.1.70+ (service-go-grpc#214) builds a static service's final image
FROM scratchwhen it has neither CGO norruntime-packages(templates/builder/Dockerfile.tmpl:if and (not .WithCGO) (not .RuntimePackages)).runtime-packages, so its runtime image moves from alpine to scratch. Review found noos/exec,time.LoadLocationor temp-dir use in the gateway's code, and its liveness probe is TCP, so nothing needs a shell, tzdata or/tmp.runtime-packages: [git], so it stays onalpine:3.23.7.codefly sync servicefailed on accounts under 0.1.72, for two reasons:plugins/plugins.yamlusedimport:, and the agent readspackage:.Without the plugin listed, 0.1.72's main-only refresh would rewrite
code/main.goas follows:authoritygRPC endpoint declared inservice.codefly.yamlnever reachesConfiguration.EndpointAuthorityPort, so that listener is never bound.server.Startbeforework(ctx), so handlers are served while the business service is still nil, and a port probe races readiness. Accounts deliberately finishes wiring, plugin registration and fixture seeding before any listener opens.0.1.58 never synced either file, so both have been maintained by hand under a
DO NOT EDITmarker. Stopgap, not a fix:main.godrops the generated-code marker, so sync leaves it alone.registry_gen.gobecomes a hand-writtenplugins/registry.go, andplugins.yamlis deleted. Both files carry aSTOPGAP (codefly-dev/service-go-grpc#223)header. Sync cannot keep a multi-service, custom-adapter service's entrypoint and plugin registry generated service-go-grpc#223 asks for the shape accounts needs: a plugin registry without a single scaffold service, every declared endpoint (or a documentedConfigureseam) in the generated main, and a stated ordering seam. Once it lands, accounts restores the marker and adopts the generated main. Sync is now clean for both services. The CUSTOM hooks inconnect_gen.goare untouched.codefly generate runnables: the three accounts runnable packages record the agent version, so they and their digests change.generate contracts --checkandcheck-generated-libraries.share clean with CI's CLI 0.1.221. Under 0.1.233 only thegenerated-byprovenance changed, so I did not commit that.scripts/ci/build-images.json: go-grpc 0.1.72 builds ongolang:1.27.3-alpine3.23@sha256:8a504649…and runs onalpine:3.23.7@sha256:ff7f0c72…(the agent'sbuild_images.go/AlpineDigest; 3.23.7 carries OpenSSL 3.5.9 and musl 1.2.5-r24). The build-evidence gate refused accounts and auth-gateway until the image contract moved with the agent, as RELEASE_GATES.md requires.build-images.test.mjspasses.Frontend advisories (the supply-chain red), fixed in the frontend's own manifests:
follow-redirects1.16.1 → 1.16.2 (GHSA-mrwp-f3q8-3g9p, high). Changed in the lockfile only, inside axios's^1.16.0.fast-uri3.1.8 → 3.1.9 (GHSA-w74x-v6f9-j3xg, GHSA-wjr9-j795-jxcr, GHSA-xhq7-xmqj-769h, GHSA-333x-w4r6-6crp), through the existing override, now<3.1.9 → 3.1.9.npm audit fixwas not used.deepmerge4.3.1 (GHSA-gcqx-w48m-w2h4, low, via swagger-client) has no patched release. It stays, below the job's--audit-level=high. The repo documents no advisory allowlist, and Frontend production dependency has a high-severity advisory with no patched release in the declared major; automatic remediation refuses it by design #1237 rules allowlisting out.Authority libraries. In accounts'
go.mod, authority-core, authority-client and conformance move from d0210535 (Generate exact bootstrap network policies (#61) #62) to authority main dea37afa (Generate ambient authorization for internal topology edges #65). At the old pin, the conformance case "a standing one-second delegation does not issue … parent session expired" raced the parent session's whole-second expiry and turned the pinned conformance job red. Generate ambient authorization for internal topology edges #65 fixes it.Tests
accounts
go build ./... && go test ./...: passed twice on the agent move. At dea37afa: full suite including conformance passes, and conformance passes 3× more with-count=3. Onepkg/businessfailure in the full run was the test store's Postgres port collision (could not bind 127.0.0.1:49740: Address already in use); it passed when re-run alone.auth-gateway build + tests: pass
module/tools and root
go test: passcheck-boundaries.sh, naming gate (tests and records), agent-docs links: passFrontend: CI's exact
npm audit --omit=dev --audit-level=highpasses on frontend and marketing;npm run typecheckpasses;test:purepasses (357 files / 5064 tests);module-verify.mjsinstall graph in syncComposed boot on 0.1.72. I ran
codefly run servicefrom auth-gateway (CLI 0.1.233, workspacelocalenv,--fixture dev-admin,--naming-scope pr1287).Running on :7243) and auth-gateway (Running in 25.4s) all reached Running. No "exceeds its limit" refusal appeared.CODEFLY__keys, each exactly once.GET /health,/healthzand/readyreturn 200{"status":"ok"}.GET /v1/auth/.well-known/jwks.jsonreturns 200 with an Ed25519 key. The sign-in routePOST /v1/auth/authenticatewith an empty body returns accounts' 400 validation error through the gateway.…-object-storage-pr1287-{gateway,minio}), which I removed by hand.Not verified: a container (
--runtime-context container) or cluster boot, so the gateway's new scratch image has not been booted.🤖 Generated with Claude Code