Keep GPU bridge test independent of daily cleanup time - #37
Merged
Merged
Conversation
gaochangw
commented
Sep 14, 2026
gaochangw
left a comment
Member
Author
There was a problem hiding this comment.
Reviewed commit 75321ca. No actionable findings.
The fixed clock is passed to the tenant manager and scoped to the GPU broker module, so session expiry and GPU job expiry agree without changing the process-wide clock. Monotonic lease timing, asynchronous waits and the existing lost-lease assertions remain real. The patch is restored by pytest after the application shuts down.
Validation: 43 targeted integration tests passed, including the separate test that advances into the cleanup window, rejects new sessions and verifies temporary files are purged. The diff contains only this test fixture adjustment and a clearer session-status assertion; there are no runtime, packaging or deployment changes.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The GPU bridge integration test assumed anonymous sessions could be created at any real-world time. During the 23:55–00:00 UTC daily cleanup window, the API correctly returned HTTP 503 and the test failed while indexing
access_token.Use one fixed daytime clock for session and GPU job expiry. Preserve real monotonic timing for polling and lost-lease checks, and assert HTTP 201 before reading a session token. This changes test setup only; production cleanup behavior and the published 2.2.5 artifacts are unchanged.
Validation:
tests/integration/test_gpu_bridge.pyandtests/integration/test_public_studio.py— 43 passed, including session expiry, disk cleanup, GPU lease loss, replay and cross-tenant isolation.Observed failure: the post-merge Python 3.11 run at 23:57 UTC in CI 34790882657. The same release commit passed all PR checks before the cleanup window.