Update (6/6/22): Just encountered this error again. I swear it comes back to taunt me every few months, then goes away just as randomly. Am I missing some documentation somewhere that explains what this means, or what I'm supposed to do? Since when do SFDX CLI commands involve an ID? Since when do I need to start a 'new job' to issue a sfdx force:source:deploy
command? aaargh
Attempting to do deployments from SFDX. The same command line that worked just fine last night is now failing this morning.
Attempts such as
sfdx force:source:deploy -c -p force-app/main/default
or
sfdx force:source:deploy -c -x package.xml
return the same error:
ERROR running force:source:deploy: Metadata API request failed: The deploy operation is missing a job ID. Initialize an operation with an ID, or start a new job.
I can find no results on google explaining this error or what the fix is. Dev documentation doesn't show any sfdx commands related to initializing a job ID (I thought those were assigned automatically?), or starting a new job (I thought that's what running a new deployment command was?).
I ran the exact same command to the same org last night and it deployed successfully.
I updated SFDX to the latest version, no effect.
I can use the sfdx force:source:retrieve
command successfully as well.
Anyone see this error before?
~/.sfdx/stash.json
file - does it contain a jobId?stash.json
file in that directory, just asfdx-config.json
sfdx-config.json
is in your repo directory. I'm talking about looking, if on windows, in yourC:\Users\YourUser\.sfdx
folder. I believe that file,stash.json
is where the tool stores job Ids so was intrigued to see if you had it or if it had values.{ "MDAPI_RETRIEVE": { "jobid": "09S03000001OOwpEAG", "retrievetargetdir": "C:\\Users\\smohyee\\AppData\\Local\\Temp\\sdx_sourceRetrieve_pkg_1623097891473" }, "SOURCE_DEPLOY": { "jobid": "0Af0500000X8EKmCAN" } }