Closed JavierCarvajalLBS closed 7 months ago
Thank you for filing this issue. We appreciate your feedback and will review the issue as soon as possible. Remember, however, that GitHub isn't a mechanism for receiving support under any agreement or SLA. If you require immediate assistance, contact Salesforce Customer Support.
I forgot to mention that the issue happens in a Production org. With the same command and package in a sandbox, validation cancels after more than 20 minutes due to insufficient code coverage in a trigger due to the execution of all local tests in the sandbox.
This issue has been linked to a new work item: W-15207335
Looks like you can get the detailed failure messages if you don't use the --json
flag. This happens when there are errors in the deployed metadata components. We'll fix the bug. Thanks for reporting.
@shetzel you were right When I removed the --json parameter and executed the validation again, I could read the entire response in the log file. Then, we´ll wait until it is fixed, as we need to capture the response in a json file to analyze and extract everything.
This issue is fixed in Salesforce CLI release 2.33.3.
Summary
When running a "sf project deploy validate" command, the validation fails, but the only message received is:
FailedValidationError: Failed to validate the deployment (XXXXXXXXXXXXX). Due To:\n1 component error(s)
Steps To Reproduce
The following command was executed:
project deploy validate --manifest \"${PACKAGE_XML_PATH}\" --test-level RunLocalTests --wait 120 --verbose --target-org Prod --json > output.txt
The package.xml contains:
Expected result
The deployment should be validated or, if canceled, an explanation of the cancelation reason should be received.
Actual result
The validation is canceled after a couple of minutes with the following message:
FailedValidationError: Failed to validate the deployment (XXXXXXXXXXXXX). Due To:\n1 component error(s)
System Information
The command is executed through a Jenkins job, that can deploy without issues. Now, we are including the validation option.
The sf CLI was updated today with the latest version available