Azure / Azure/azure-devops-cli-extension
[Bug] Az CLI does not pass along exit code from ArtifactTools
- Dominant language
- Python
- Stars
- 682
- Forks
- 278
- Avg merge
- 3d 23h
- Merged PRs (30d)
- 3
Description
When artifacttools return an exit code from [this ](https://dev.azure.com/mseng/AzureDevOps/_git/ArtifactTool?path=%2Fsrc%2FArtifactTool%2FErrorCode.cs) list it doesn't get pass along to AZ cli interface and always show exit code 1.
Azure-Devops extension version: :
azure-devops (0.18.0)
Steps to reproduce the behavior:
Trigger any error listed in the list above. For example, attempting to publish a package where the version already existed before. No information of the exit code can be found with --debug flag on. However, running external command for artifacttools directly will change environmental variable $LASTEXITCODE to the correct exit code.
**Debug logs**

Related bugs created in Azure DevOps:
https://dev.azure.com/mseng/AzureDevOps/_workitems/edit/1308350
https://dev.azure.com/mseng/AzureDevOps/_workitems/edit/1302921
Contributor guide
Assessment
This issue has not been assessed yet.