Open
Description
New issue checklist
- I searched for existing GitHub issues
- I read pipeline troubleshooting guide
- I checked how to collect logs
Task name
AzureFileCopy
Task version
6.243.0
Issue Description
We've been experiencing intermittent issues with StackOverflowException in this task. It seems very likely to be related to #20156
We've experienced this failure on 6.243.0, 6.242.10, and 6.242.6 (I can't find it happening on older versions, but our job is only daily so that's not a guarantee)
Environment type (Please select at least one enviroment where you face this issue)
- Self-Hosted
- Microsoft Hosted
- VMSS Pool
- Container
Azure DevOps Server type
dev.azure.com (formerly visualstudio.com)
Azure DevOps Server Version (if applicable)
No response
Operation system
Windows Server 2022
Relevant log output
2024-07-29T12:05:44.3955659Z ##[section]Starting: Upload index to Azure Stroage
2024-07-29T12:05:44.3968038Z ==============================================================================
2024-07-29T12:05:44.3968174Z Task : Azure file copy
2024-07-29T12:05:44.3968233Z Description : Copy files to Azure Blob Storage or virtual machines
2024-07-29T12:05:44.3968327Z Version : 6.243.0
2024-07-29T12:05:44.3968383Z Author : Microsoft Corporation
2024-07-29T12:05:44.3968488Z Help : https://docs.microsoft.com/azure/devops/pipelines/tasks/deploy/azure-file-copy
2024-07-29T12:05:44.3968585Z ==============================================================================
2024-07-29T12:05:45.8990841Z Added TLS 1.2 in session.
2024-07-29T12:05:46.2175009Z ##[command]Import-Module -Name C:\Modules\az_11.3.1\Az.Accounts\3.0.2\Az.Accounts.psd1 -Global
2024-07-29T12:05:49.7890152Z ##[command]Update-AzConfig -DisplayBreakingChangeWarning False -AppliesTo Az
2024-07-29T12:05:49.9407665Z
2024-07-29T12:05:50.0271404Z ##[command]Enable-AzureRmAlias -Scope Process
2024-07-29T12:05:51.2715650Z
2024-07-29T12:05:51.2716199Z Process is terminated due to StackOverflowException.
2024-07-29T12:06:11.1659556Z ##[error]Exit code 57005 returned from process: file name 'C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe', arguments '-NoLogo -Sta -NoProfile -NonInteractive -ExecutionPolicy Unrestricted -Command ". ([scriptblock]::Create('if ([Console]::InputEncoding -is [Text.UTF8Encoding] -and [Console]::InputEncoding.GetPreamble().Length -ne 0) { [Console]::InputEncoding = New-Object Text.UTF8Encoding $false } if (!$PSHOME) { $null = Get-Item -LiteralPath ''variable:PSHOME'' } else { Import-Module -Name ([System.IO.Path]::Combine($PSHOME, ''Modules\Microsoft.PowerShell.Management\Microsoft.PowerShell.Management.psd1'')) ; Import-Module -Name ([System.IO.Path]::Combine($PSHOME, ''Modules\Microsoft.PowerShell.Utility\Microsoft.PowerShell.Utility.psd1'')) }')) 2>&1 | ForEach-Object { Write-Verbose $_.Exception.Message -Verbose } ; Import-Module -Name 'D:\a\_work\_tasks\AzureFileCopy_eb72cb01-a7e5-427b-a8a1-1b31ccac8a43\6.243.0\ps_modules\VstsTaskSdk\VstsTaskSdk.psd1' -ArgumentList @{ NonInteractive = $true } -ErrorAction Stop ; $VerbosePreference = 'SilentlyContinue' ; $DebugPreference = 'SilentlyContinue' ; Invoke-VstsTaskScript -ScriptBlock ([scriptblock]::Create('. ''D:\a\_work\_tasks\AzureFileCopy_eb72cb01-a7e5-427b-a8a1-1b31ccac8a43\6.243.0\AzureFileCopy.ps1'''))"'.
2024-07-29T12:06:11.1674268Z ##[section]Finishing: Upload index to Azure Stroage
Full task logs with system.debug enabled
[REPLACE THIS WITH YOUR INFORMATION]
Repro steps
- task: AzureFileCopy@6
displayName: Upload index to Azure Stroage
inputs:
azureSubscription: SourceDotNet-Deployment-ARM
SourcePath: "bin/index/index/*"
Destination: AzureBlob
storage: $(storageAccount)
ContainerName: $(NEW_CONTAINER_NAME)
Activity