Coder Social home page Coder Social logo

Comments (4)

v-schhabra avatar v-schhabra commented on September 26, 2024 1

Hi @chrisfcarroll
Msbuild task is owned by ABTT team.
I just tagged them here. I hope they will get notify now about this issue.
image

from azure-pipelines-tasks.

andersforsgren avatar andersforsgren commented on September 26, 2024

This happens still,

Current agent version: '3.239.1'
...
##[error]Process 'msbuild.exe' exited with code ''.

Assuming this happens in azure-pipelines-tasks-lib (ToolFunctions.ps1):

Tasks/MSBuildV1/msbuild.ts

        Write-Verbose "Exit code: $LASTEXITCODE"
        if ($RequireExitCodeZero -and $LASTEXITCODE -ne 0) {
            Write-Error (Get-LocString -Key PSLIB_Process0ExitedWithCode1 -ArgumentList ([System.IO.Path]::GetFileName($FileName)), $LASTEXITCODE)
        }

Is $LASTEXITCODE being unset really properly handled here?

When the process fails, the last project compiled looks like this with diagnostics on:

  MyAssembly -> C:\TfsAgent\2\_work\1\b\MyAssembly.dll
##[debug]Processed: ##vso[task.logdetail id=a2d0fbce-2ff3-4051-933a-1b6bf83d692e;parentid=2f9f376e-54a7-4e8a-9111-009e62b62380;type=Build;result=Succeeded;finishtime=2024-08-06T12:59:55.6167709Z;progress=100;state=Completed;parentid=2f9f376e-54a7-4e8a-9111-009e62b62380;name=;]
##[debug]Processed: ##vso[task.logdetail id=2f9f376e-54a7-4e8a-9111-009e62b62380;parentid=6ebdce3e-7521-4440-9e33-5777f1abc1a5;type=Build;result=Succeeded;finishtime=2024-08-06T12:59:55.6167709Z;progress=100;state=Completed;parentid=6ebdce3e-7521-4440-9e33-5777f1abc1a5;name=;]
##[debug]Exit code: 
##[debug]Error record:
##[debug]Invoke-VstsProcess : Process 'msbuild.exe' exited with code ''.
##[debug]At C:\TfsAgent\2\_work\_tasks\VSBuild_71a9a2d3-a98a-4caa-96ab-affca411ecda\1.231.0\node_modules\azure-pipelines-tasks-msbuildhelpers\InvokeFunctions.ps1:126 char:17
##[debug]+ ...             Invoke-VstsProcess -FileName $MSBuildPath -Arguments $arg ...
##[debug]+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
##[debug]    + CategoryInfo          : NotSpecified: (:) [Write-Error], WriteErrorException
##[debug]    + FullyQualifiedErrorId : Microsoft.PowerShell.Commands.WriteErrorException,Invoke-VstsProcess
##[debug] 
##[debug]Script stack trace:
##[debug]at Invoke-Process, C:\TfsAgent\2\_work\_tasks\VSBuild_71a9a2d3-a98a-4caa-96ab-affca411ecda\1.231.0\ps_modules\VstsTaskSdk\ToolFunctions.ps1: line 217
##[debug]at Invoke-MSBuild, C:\TfsAgent\2\_work\_tasks\VSBuild_71a9a2d3-a98a-4caa-96ab-affca411ecda\1.231.0\node_modules\azure-pipelines-tasks-msbuildhelpers\InvokeFunctions.ps1: line 126
##[debug]at Invoke-BuildTools, C:\TfsAgent\2\_work\_tasks\VSBuild_71a9a2d3-a98a-4caa-96ab-affca411ecda\1.231.0\node_modules\azure-pipelines-tasks-msbuildhelpers\InvokeFunctions.ps1: line 42
##[debug]at <ScriptBlock>, C:\TfsAgent\2\_work\_tasks\VSBuild_71a9a2d3-a98a-4caa-96ab-affca411ecda\1.231.0\VSBuild.ps1: line 103
##[debug]at <ScriptBlock>, <No file>: line 1
##[debug]at <ScriptBlock>, <No file>: line 22
##[debug]at <ScriptBlock>, <No file>: line 18
##[debug]at <ScriptBlock>, <No file>: line 1
##[debug]Exception:
##[debug]Microsoft.PowerShell.Commands.WriteErrorException: Process 'msbuild.exe' exited with code ''.
##[error]Process 'msbuild.exe' exited with code ''.
##[debug]Processed: ##vso[task.logissue type=error]Process 'msbuild.exe' exited with code ''.
##[debug]Leaving Invoke-VstsProcess.
##[debug]Processed: ##vso[task.complete result=Failed]
##[debug]Processed: ##vso[task.logdetail finishtime=2024-08-06T12:59:55.8198861Z;id=6ebdce3e-7521-4440-9e33-5777f1abc1a5;progress=100;state=Completed;result=Failed]
##[debug]Leaving Invoke-MSBuild.
##[debug]Leaving Invoke-BuildTools.
##[debug]AGENT_VERSION: '3.239.1'

from azure-pipelines-tasks.

chrisfcarroll avatar chrisfcarroll commented on September 26, 2024

Could this be something that only happens on self-hosted agents?

I'm using self-hosted agents, and it looks to me that OP is too.

from azure-pipelines-tasks.

chrisfcarroll avatar chrisfcarroll commented on September 26, 2024

@DenisRumyantsev , @v-schhabra : my apologies for @-ing you but it looks like this has been triaged into Azure:Artifacts by a bot, where it is receiving no attention perhaps because it is not related to artifacts ?

from azure-pipelines-tasks.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.