Repository navigation
test(scripts): opt fleet-soak agents into portwing's plaintext edge URL gate - #898
Conversation
…RL gate Backport of dcd211a (#870) from dev/v1.7. portwing v0.9.9 (CodesWhat/portwing#201) fails closed on http:// and ws:// controller URLs in edge mode unless ALLOW_INSECURE_EDGE_URL=true. The soak spawns agents against http://127.0.0.1 by design, so since that release every agent exited at config load and the run timed out at 0/8 registered. Set the opt-in in spawnAgent's env and guard it with a source assertion so it can't be dropped silently. Portwing's hardening is correct and intentional; the harness just hadn't caught up. v1.6 needs this independently of v1.7. Dispatching the soak on unmodified dev/v1.6 reproduces the failure byte-for-byte against portwing edf7394e, and it stayed red on #895 where the only diff was three display-name strings. Not a protocol break and not user-facing: portwing has always documented edge mode's controller trust as TLS-only, so this only bites the harness's loopback dial. (cherry picked from commit dcd211a)
|
Deployment failed for project drydock-website with the following error: |
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (2)
Included review availability: Your plan provides up to 2 included reviews per hour; 0 remain after this review. 📝 WalkthroughWalkthrough
Merge Risk: ⚪ Minimal · up to This localized test-harness change enables the fleet-soak agents to use the required loopback URL opt-in and adds a source assertion to preserve that behavior; no actionable merge-blocking risk remains. 🚥 Pre-merge checks | ✅ 2✅ Passed checks (2 passed)
✨ Finishing Touches 💡 1🛠️ Fix failing CI checks 💡
📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
@coderabbitai review |
✅ Action performedReview finished.
|
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
biggest-littlest
left a comment
There was a problem hiding this comment.
Straight cherry-pick of dcd211a, verified against the file rather than the diff: the opt-in is at portwing-fleet-soak.mjs:318 and the source assertion at portwing-fleet-soak.test.mjs:64,67. The soak itself is green on this PR, which is the part that matters here since the workflow is in its own paths filter and so actually ran.
ALARGECOMPANY
left a comment
There was a problem hiding this comment.
Agreed this is a harness fix and not a compatibility one. portwing has documented edge mode as TLS-only since well before v0.9.9, so the gate only bites the soak's loopback dial and no supported deployment changes behaviour. Checked the failure was pre-existing on dev/v1.6 independently of #895.
Backport of
dcd211a3(#870) fromdev/v1.7. Straight cherry-pick, 2 files, 19 insertions, no conflicts.What broke
portwing v0.9.9 (
CodesWhat/portwing#201) added a fail-closed check: edge mode refuses to start whenDRYDOCK_URLuses a plaintexthttp://orws://scheme, unlessALLOW_INSECURE_EDGE_URL=trueis also set.scripts/portwing-fleet-soak.mjsspawns its agents againsthttp://127.0.0.1:<port>by design. Since that release every agent process exits at config parse, before attempting a WebSocket handshake, and the run times out withinitialConnections: 0.Why this is v1.6's problem independently of v1.7
The workflow checks out
CodesWhat/portwingatref: main, a floating ref, so the gate arrived on a branch nobody was changing. Two things pin the cause to portwing rather than to anything here:dev/v1.6(run 33046671451, drydocke8638817) reproduces it byte-for-byte against portwingedf7394e.dev/v1.7took the opt-in on 2026-08-25 and has been green since.dev/v1.6never got it, so the soak has been deterministically red here since 2026-08-23.Not a user-facing break
portwing has always documented edge mode's controller trust as TLS-only, and the supported form is
DRYDOCK_URL=https://.... Anyone running drydock behind TLS sees no change on either line. The soak's loopback dial is what trips the new gate, which makes this a harness fix, not a compatibility fix.The 16 lines in
portwing-fleet-soak.test.mjsare a source assertion so the opt-in can't be dropped silently later.Worth doing separately
ref: mainon a cross-repo checkout means a green run only proves compatibility with whatever portwing was at that minute, and a red one can't distinguish "we broke it" from "they shipped". That cost a diagnosis here and, separately, one in sockguard from the same portwing change. Tracked for follow-up; out of scope for a backport.Changelog
scripts/portwing-fleet-soak.mjsto setALLOW_INSECURE_EDGE_URL: 'true'for spawned agents.