Skip to content

[windows-integration] Bound redirected output draining in Windows CLI integration tests #72008

Done

Description

@github-actions

Overview

The integration helper bounds the CLI process wait, but output draining after process exit can still block without a timeout. Please update the Windows integration workflow so pipe draining is bounded and reports captured output on timeout.

Finding

Invoke-CliProcess in .github/workflows/windows-cli-integration.yml uses WaitForExit($TimeoutMs) and kills the child tree if that wait expires. After a successful process exit, it then calls WaitForExit() and synchronously awaits both ReadToEndAsync() tasks with GetAwaiter().GetResult(). If a descendant keeps an inherited stdout or stderr pipe open, those reads can remain pending after the CLI process has exited. The step then relies on the job-level timeout instead of surfacing the explicit TIMEOUT message and captured output.

Requested update

Bound stdout and stderr draining after process exit as well. On a drain timeout, terminate any remaining process tree where possible and throw an explicit timeout diagnostic that includes the command, elapsed time, and captured output. Keep the existing fast failure behavior for ordinary process timeouts.

Review context

This was identified by static review of the integration helper and its callers; no workflow run failure is being asserted. The workflow already has a separate bounded ConPTY drain path.

Next action

Update the workflow and its regression checks to cover a child that exits while a descendant holds a redirected output pipe open.

References: §40271343670

Generated by 🪟 Daily Windows Terminal Integration Builder · codex · gpt60 · ~1 AIC · ⌖ ~1 AIC · ⊞ 15.2K · ◷

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions