Skip to content

Kill build processes when prepareMachine is set regardless of ci - #17095

Merged
ViktorHofer merged 1 commit into
mainfrom
copilot/update-prepare-machine-flag
Jul 10, 2026
Merged

ViktorHofer merged 1 commit into
mainfrom
copilot/update-prepare-machine-flag

Conversation

Copilot AI commented Jul 10, 2026

Copy link
Copy Markdown
Contributor

The prepareMachine / prepare_machine flag is documented as machine cleanup that "kills build processes," but ExitWithExitCode only stopped processes when ci was also true—so setting the flag alone had no effect on non-CI machines.

Changes

  • eng/common/tools.ps1 — ExitWithExitCode calls Stop-Processes when $prepareMachine, dropping the $ci guard.
  • eng/common/tools.sh — ExitWithExitCode calls StopProcesses when $prepare_machine, dropping the $ci check.

To double check:

Copilot AI requested review from Copilot and removed request for Copilot July 10, 2026 13:43
@ViktorHofer
ViktorHofer marked this pull request as ready for review July 10, 2026 13:43
Copilot AI review requested due to automatic review settings July 10, 2026 13:43

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR fixes the prepareMachine / prepare_machine behavior in Arcade’s shared build tooling so that enabling machine-preparation cleanup reliably kills build-related processes on script exit, even when not running in CI. This aligns the implementation with how the flag is documented and expected to work.

Changes:

  • Update ExitWithExitCode in the Bash tooling to call StopProcesses whenever prepare_machine is true (no longer gated by ci).
  • Update ExitWithExitCode in the PowerShell tooling to call Stop-Processes whenever prepareMachine is true (no longer gated by ci).
Show a summary per file
File Description
eng/common/tools.sh Removes the ci guard so --prepareMachine triggers process cleanup on exit in Bash runs.
eng/common/tools.ps1 Removes the ci guard so -prepareMachine triggers process cleanup on exit in PowerShell runs.

Copilot's findings

Tip

Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

  • Files reviewed: 2/2 changed files
  • Comments generated: 0

@ViktorHofer
ViktorHofer enabled auto-merge (squash) July 10, 2026 14:08
@ViktorHofer
ViktorHofer merged commit d57e95c into main Jul 10, 2026
10 of 11 checks passed
@ViktorHofer
ViktorHofer deleted the copilot/update-prepare-machine-flag branch July 10, 2026 15:07
@dotnet-milestone-bot dotnet-milestone-bot Bot added this to the 11.0-preview7 milestone Jul 13, 2026
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.

4 participants