I have been working on some classes using VS code and SFDX. I created a scratch org and pushed code to it using:

sfdx force:source:push -u MY_ORG_ALIAS

The push was successful.

I continued development and I happen to miss a semicolon in code. I hit the push command but this time instead of throwing a compilation issue DX thew this:

ERROR running force:source:push: Push failed.

I have been working on DX for months now and I have always seen a compilation error message and never this.

I then ran this sfdx force:source:push -u MY_ORG_ALIAS --dev-debug

This was the output of the command: enter image description here

Has something changed with DX? Am I missing something here?

  • 1
    Could you update your CLI with sfdx update command and try again, otherwise, from command line call push with --json flag. – Raul Jun 28 '19 at 6:18
  • @Raul I had updated the CLI but didn't try the json flag which seems to be giving the error message, so that worked just fine! Thank you! – d_k Jun 28 '19 at 6:23

The push and deploy were broken in a version of CLI 10 days ago, although its fixed in latest sfdx cli version; some of us still face the issue.

If updating sfdx CLI with sfdx command does not resolves the issue, workaround is to :

  1. Add --json flag to the push command, it usually displays all errors in JSON format.
  2. Monitor deployments from Salesforce setup (this could be annoying as you have to leave your editor to see the error).

To get a proper resolution, please log an issue with salesforcedx-vscode team on github, they are quite active and doing a great job with fixes.

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.