Failed after TLTanner Linsley
View latest

docs: address agent skill review feedback

78671802a75Open on GitHub

Self-Healing CI

Classification: Code change neededFix generatedVerified 1 task

We fix the EADDRINUSE error by adding a module-level _allocatedPorts set in derivePort.ts that tracks every port assigned within the current process. When rm -rf port*.txt clears all cached port files before each test run, both getTestServerPort and getDummyServerPort called getRandomPort() in rapid succession and consistently received the same port (43099), because getRandomPort temporarily binds then immediately releases a port — leaving it free for the very next call. The do/while loop now retries until a port not already in the set is returned, guaranteeing unique ports across all derivePort invocations in the same process.

Commit"fix(e2e-utils): prevent duplicate port allocation in derivePort"

1 file changed