Skip to content

Conversation

@jsonbailey
Copy link
Contributor

@jsonbailey jsonbailey commented Jan 15, 2026

Several properties are lazy loaded in the req object. If we want to access their properties later it introduces a race condition. We should copy all information during the request that we want to use later.


Note

Stabilize flaky SSE client specs

  • Replace queued req objects with snapshot request_data hashes (e.g., headers, method, body) captured before closing the stream to avoid lazy-loaded property races
  • Update expectations to reference request_data (e.g., received_req[:headers], [:method], [:body]), including reconnect Last-Event-Id and payload-as-JSON assertions
  • Minor cleanups: add explanatory comments and variable renames (e.g., _req1) to clarify unused values

Written by Cursor Bugbot for commit 5fb9d58. This will update automatically on new commits. Configure here.

@jsonbailey jsonbailey requested a review from a team as a code owner January 15, 2026 18:33
@jsonbailey jsonbailey merged commit 36c1c9b into main Jan 15, 2026
11 checks passed
@jsonbailey jsonbailey deleted the jb/sdk-1751/fix-flaky-unit-tests branch January 15, 2026 18:42
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.

3 participants