iris: add --async to gcloud delete commands to unblock heartbeat thread#3684
Closed
ravwojdyla-agent wants to merge 2 commits intomainfrom
Closed
iris: add --async to gcloud delete commands to unblock heartbeat thread#3684ravwojdyla-agent wants to merge 2 commits intomainfrom
ravwojdyla-agent wants to merge 2 commits intomainfrom
Conversation
Fixes #3678 (item 3). All five gcloud delete call sites in gcp.py were synchronous, blocking the calling thread for 10-18s (TPU) or 3-5s (GCE). The heartbeat thread was observed stuck on these calls, stalling task dispatches. Adding --async tells gcloud to return immediately after initiating the deletion; validation errors are still caught synchronously. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
rjpower
reviewed
Mar 14, 2026
| assert listed_by_id[handle.slice_id].created_at.epoch_ms() == expected_epoch_ms | ||
|
|
||
|
|
||
| def test_gcp_terminate_passes_async_flag(): |
Collaborator
There was a problem hiding this comment.
Let's remove this test, we either added the flag or we didn't
rjpower
reviewed
Mar 14, 2026
| assert "--async" in cmd, f"Missing --async in delete command: {cmd}" | ||
|
|
||
|
|
||
| def test_gcp_best_effort_delete_passes_async_flag(): |
Collaborator
|
@claude remove dumb tests |
Contributor
|
@claude address the comments above please |
rjpower
approved these changes
Mar 14, 2026
Collaborator
rjpower
left a comment
There was a problem hiding this comment.
@ravwojdyla you can pick :)
Contributor
|
Claude finished @rjpower's task in 2m 9s —— View job Removing flagged tests
Removed both |
Contributor
|
Claude finished @ravwojdyla's task in 2m 5s —— View job Addressing review comments
The two |
The --async flag is either present in the code or it isn't — dedicated tests for its presence add no value. Co-authored-by: Russell Power <rjpower@users.noreply.github.com> Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
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.
Summary
--asyncflag to all 5gcloud ... deletecall sites ingcp.py(3terminate()methods + 2_best_effort_delete_*helpers)gcloud tpu-vm deletewas blocking heartbeat/autoscaler threads for 10-18s per callreboot()— only delete operationsTest plan
--asyncis present in all delete commands (test_gcp_terminate_passes_async_flag,test_gcp_best_effort_delete_passes_async_flag)Fixes #3678
🤖 Generated with Claude Code