Skip to content

test(core/030): retry connect to kill status=0 flake (#48)#56

Merged
EdmondDantes merged 1 commit into
mainfrom
fix-030-connect-retry
May 29, 2026
Merged

test(core/030): retry connect to kill status=0 flake (#48)#56
EdmondDantes merged 1 commit into
mainfrom
fix-030-connect-retry

Conversation

@EdmondDantes
Copy link
Copy Markdown
Contributor

core/030-response-json flaked on main CI with status=0 for some sub-requests: fetch() didn't guard stream_socket_client returning false, so a transient connect failure under parallel run-tests -j load (first attempt racing the accept loop) produced empty reads → status 0.

Fix: retry the connect up to 20×10 ms and return a clean [0,[],''] on total failure. The JSON response semantics under test are unchanged. 5/5 stable locally. Tracked under #48.

030's fetch() didn't guard stream_socket_client returning false, so a
transient connect failure under parallel run-tests load (the first
attempt racing the accept loop) surfaced as a flaky status=0 — seen on
main CI. Retry the connect up to 20×10ms and return a clean [0,[],''] if
it never succeeds. Test semantics (JSON response behaviour) unchanged;
5/5 stable locally.
@github-actions
Copy link
Copy Markdown
Contributor

Coverage

Total lines: 80.80% → 80.66% (-0.14 pp)

File Baseline Current Δ Touched
src/core/http_connection.c 69.65% 67.68% -1.96 pp

@EdmondDantes EdmondDantes merged commit d120757 into main May 29, 2026
8 checks passed
@EdmondDantes EdmondDantes deleted the fix-030-connect-retry branch May 29, 2026 19:30
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