Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG]: Incomplete output - ##[error]Bash exited with code '100'. #8729 #4505

Closed
1 of 4 tasks
AzaruddinKhan opened this issue Nov 3, 2023 · 9 comments
Closed
1 of 4 tasks
Assignees

Comments

@AzaruddinKhan
Copy link

What happened?

Hi,
I am using vmImage: "ubuntu-22.04" to run the test classes in Salesforce & return the result after the execution.

What I observed is that after the execution the output is not completed populated & in a result the job fails with below exception .
error ##[error]Bash exited with code '100'.

Versions

Hi,
I am using vmImage: "ubuntu-22.04" to run the test classes in Salesforce & return the result after the execution.

What I observed is that after the execution the output is not completed populated & in a result the job fails with below exception .
error ##[error]Bash exited with code '100'.

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

vmImage: "ubuntu-22.04"

Version controll system

git azure devops repos

Relevant log output

It should generate the complete output and should go to next step for job closure.

 am using vmImage: "ubuntu-22.04" to run the test classes in Salesforce & return the result after the execution.

What I observed is that after the execution the output is not completed populated & in a result the job fails with below exception .
error ##[error]Bash exited with code '100'.

Repro steps
Use the image vmImage: "ubuntu-22.04" & run all the test classes of the org in with the below command.

sfdx force:apex:test:run -u codecoverage -l RunLocalTests -c -r human --synchronous
@vmapetr
Copy link
Contributor

vmapetr commented Nov 9, 2023

Hi @AzaruddinKhan thank you for reporting!
To help us with the investigation, could you please provide additional information:
Have you tried to run the same tests on the self-hosted agent?
Could you please provide debug logs from the failed stage - you can enable the debug output using the following instructions - https://learn.microsoft.com/en-us/azure/devops/pipelines/troubleshooting/review-logs?view=azure-devops#configure-verbose-logs

@AzaruddinKhan
Copy link
Author

Hi @vmapetr ,

Thanks for your response!
Please find the more details after enabling the logs.

Screenshot 2023-11-10 at 4 23 59 PM

@AzaruddinKhan
Copy link
Author

`##[debug]Evaluating condition for step: 'Run Apex Tests'
##[debug]Evaluating: SucceededNode()
##[debug]Evaluating SucceededNode:
##[debug]=> True
##[debug]Result: True
Starting: Run Apex Tests

Task : Command line
Description : Run a command line script using Bash on Linux and macOS and cmd.exe on Windows
Version : 2.229.0
Author : Microsoft Corporation
Help : https://docs.microsoft.com/azure/devops/pipelines/tasks/utility/command-line

##[debug]Using node path: /home/vsts/agents/3.227.2/externals/node16/bin/node
##[debug]agent.TempDirectory=/home/vsts/work/_temp
##[debug]loading inputs and endpoints
##[debug]loading INPUT_SCRIPT
##[debug]loading INPUT_WORKINGDIRECTORY
##[debug]loading INPUT_FAILONSTDERR
##[debug]loading ENDPOINT_AUTH_SYSTEMVSSCONNECTION
##[debug]loading ENDPOINT_AUTH_SCHEME_SYSTEMVSSCONNECTION
##[debug]loading ENDPOINT_AUTH_PARAMETER_SYSTEMVSSCONNECTION_ACCESSTOKEN
##[debug]loading SECRET_SFDX_AUTH_URL_QASERVICE
##[debug]loading SECRET_SFDX_AUTH_URL_QA
##[debug]loading SECRET_SFDX_AUTH_URL_PROD
##[debug]loading SECRET_SYSTEM_ACCESSTOKEN
##[debug]loading SECRET_SFDX_AUTH_URL_CODECOVERAGE
##[debug]loading SECRET_SFDX_AUTH_URL_OMNITRAIN
##[debug]loading SECRET_SFDX_AUTH_URL_PRE_PROD
##[debug]loading SECRET_SFDX_AUTH_URL_EPOC
##[debug]loading SECRET_SFDX_AUTH_URL_UAT
##[debug]loading SECRET_SFDX_AUTH_URL_DEV
##[debug]loading SECRET_SFDX_AUTH_URL_SERVICEPOC
##[debug]loaded 17
##[debug]Agent.ProxyUrl=undefined
##[debug]Agent.CAInfo=undefined
##[debug]Agent.ClientCert=undefined
##[debug]Agent.SkipCertValidation=undefined
##[debug]check path : /home/vsts/work/_tasks/CmdLine_d9bafed4-0b18-4f58-968d-86655b4d2ce9/2.229.0/task.json
##[debug]adding resource file: /home/vsts/work/_tasks/CmdLine_d9bafed4-0b18-4f58-968d-86655b4d2ce9/2.229.0/task.json
##[debug]system.culture=en-US
##[debug]failOnStderr=false
##[debug]script=npx sfdx force:apex:test:run -u codecoverage -l RunLocalTests -c -r human --synchronous
##[debug]workingDirectory=/home/vsts/work/1/s
##[debug]check path : /home/vsts/work/1/s
Generating script.
##[debug]Agent.Version=3.227.2
##[debug]agent.tempDirectory=/home/vsts/work/_temp
##[debug]check path : /home/vsts/work/_temp
Script contents:
npx sfdx force:apex:test:run -u codecoverage -l RunLocalTests -c -r human --synchronous
========================== Starting Command Output ===========================
##[debug]which 'bash'
##[debug]found: '/usr/bin/bash'
##[debug]which '/usr/bin/bash'
##[debug]found: '/usr/bin/bash'
##[debug]/usr/bin/bash arg: --noprofile
##[debug]/usr/bin/bash arg: --norc
##[debug]/usr/bin/bash arg: /home/vsts/work/_temp/372c6a13-c05f-47f6-a730-720a20f1df8d.sh
##[debug]exec tool: /usr/bin/bash
##[debug]arguments:
##[debug] --noprofile
##[debug] --norc
##[debug] /home/vsts/work/_temp/372c6a13-c05f-47f6-a730-720a20f1df8d.sh
/usr/bin/bash --noprofile --norc /home/vsts/work/_temp/372c6a13-c05f-47f6-a730-720a20f1df8d.sh
`

@vmapetr
Copy link
Contributor

vmapetr commented Nov 12, 2023

@AzaruddinKhan thank you!
Seems like nothing suspicious in the pipeline stage logs - could you please also provide agent and worker diagnostic logs? You can find them by enabling the diagnostic run (the same instruction - https://learn.microsoft.com/en-us/azure/devops/pipelines/troubleshooting/review-logs?view=azure-devops#configure-verbose-logs) and downloading them via Download logs button in the pipeline (https://learn.microsoft.com/en-us/azure/devops/pipelines/troubleshooting/review-logs?view=azure-devops#view-and-download-logs). Required logs are named agent_$date.log and worker_$date.log and located in the Agent Diagnostic Logs/Build* folder.
It would also be great if you could provide some minimal solution that can help us to reproduce the issue.

@AzaruddinKhan
Copy link
Author

@vmapetr : Thanks for the response!

I have tried the above steps & have downloaded the logs but the folder seems to be empty. Please advise.

@vmapetr
Copy link
Contributor

vmapetr commented Nov 20, 2023

@AzaruddinKhan sorry for the delayed response.
In this case could you please help us with the investigation by providing some simple solution that can be used to reproduce this issue?
Also, did you try to execute the same tests on the self-hosted agent?

@vmapetr
Copy link
Contributor

vmapetr commented Dec 4, 2023

Hi @AzaruddinKhan, could you please confirm that the issue is still relevant?

@vmapetr
Copy link
Contributor

vmapetr commented Dec 7, 2023

Hi @AzaruddinKhan, could you please confirm that the issue still occur?

@vmapetr
Copy link
Contributor

vmapetr commented Dec 8, 2023

Hi @AzaruddinKhan closing this one as external - feel free to reopen it if the issue still occurs.

@vmapetr vmapetr closed this as completed Dec 8, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants