Skip to content

Enforce a configurable startup timeout in SnippetClientV2.start_server - #1080

Open
xpconanfan wants to merge 1 commit into
masterfrom
snippet-client-v2-start-timeout
Open

xpconanfan wants to merge 1 commit into
masterfrom
snippet-client-v2-start-timeout

Conversation

@xpconanfan

Copy link
Copy Markdown
Collaborator

Summary

  • Add server_start_timeout_sec (default 60.0, None to disable) to snippet_client_v2.Config.
  • Bound the server startup handshake in SnippetClientV2.start_server() so a hung am instrument process is terminated and raises errors.ServerStartError instead of blocking indefinitely.

SnippetClientV2.start_server previously read protocol handshake lines from the am instrument subprocess without a deadline, blocking indefinitely if instrumentation failed to start without exiting.

Add Config.server_start_timeout_sec (default 60s) and terminate the standing subprocess with a ServerStartError when the startup handshake exceeds the timeout.

This branch has not been deployed

No deployments
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