Skip to content

Conversation

@azure-sdk
Copy link
Collaborator

Sync eng/common directory with azure-sdk-tools for PR Azure/azure-sdk-tools#13561 See eng/common workflow

@azure-sdk azure-sdk requested a review from a team as a code owner January 15, 2026 22:07
@azure-sdk azure-sdk requested review from Copilot and raych1 January 15, 2026 22:07
@azure-sdk azure-sdk added EngSys This issue is impacting the engineering system. Central-EngSys This issue is owned by the Engineering System team. labels Jan 15, 2026
Copy link
Contributor

Copilot AI left a comment

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 synchronizes the eng/common directory with changes from azure-sdk-tools PR #13561. The changes improve the robustness of the MCP tool installation script by adding error handling for file copy operations and proper cleanup of temporary directories.

Changes:

  • Added error handling with graceful fallback when updating the executable fails in MCP mode
  • Implemented cleanup of temporary installation directory after copy operation
  • Modified success logging to only occur when the update actually succeeds
Comments suppressed due to low confidence (1)

eng/common/mcp/azure-sdk-mcp.ps1:178

  • When the executable update fails in MCP mode (line 149-152), the script falls back to the existing installed version but doesn't verify that $exeDestination actually exists before attempting to start it on line 178. If no previous version exists, this will cause an error. Consider adding a check like if (Test-Path $exeDestination) before the Start-Process call, or ensure the fallback message indicates the executable must already exist.
    Start-Process -WorkingDirectory $RunDirectory -FilePath $exeDestination -ArgumentList 'start' -NoNewWindow -Wait

}

if ($updateSucceeded) {
log "Executable $package is installed at $exeDestination"
Copy link

Copilot AI Jan 15, 2026

Choose a reason for hiding this comment

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

The variable reference $package uses lowercase, but the parameter is defined as $Package (uppercase P) on line 8. PowerShell is case-insensitive for variables, but for consistency and readability, the casing should match the parameter definition. Change $package to $Package.

Suggested change
log "Executable $package is installed at $exeDestination"
log "Executable $Package is installed at $exeDestination"

Copilot uses AI. Check for mistakes.
@azure-sdk azure-sdk force-pushed the sync-eng/common-users/raych1/fix-lock-issue-13561 branch from 8af8d18 to 0c1bfb9 Compare January 16, 2026 00:12
@azure-sdk azure-sdk merged commit 855a53b into main Jan 16, 2026
43 checks passed
@azure-sdk azure-sdk deleted the sync-eng/common-users/raych1/fix-lock-issue-13561 branch January 16, 2026 02:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Central-EngSys This issue is owned by the Engineering System team. EngSys This issue is impacting the engineering system.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants