dry-run project deploy affect source tracking
Summary
If I have source tracking enabled and do a dry run deploy, this appears to affect source tracking, and doing a regular "push" is subsequently affected.
Steps To Reproduce
# Make a new org
sf org create scratch --definition-file example.json --set-default
# Do a dry-run
sf project deploy start --dry-run --source-dir 'force-app'
# Do a regular push
sf project deploy start
Expected result
Code should push to the org.
Actual result
Code is not pushed to the org. The dry-run should not affect source tracking, since the org is unaffected.
Additional information
I can work around this by disabling source tracking for the dry run like so...
sf org disable tracking
sf project deploy start --dry-run --source-dir 'force-app'
sf org enable tracking
System Information
{
"architecture": "darwin-arm64",
"cliVersion": "@salesforce/cli/2.79.4",
"nodeVersion": "node-v22.12.0",
"osVersion": "Darwin 24.3.0",
"shell": "bash",
"pluginVersions": [
"@oclif/plugin-autocomplete 3.2.24 (core)",
"@oclif/plugin-commands 4.1.21 (core)",
"@oclif/plugin-help 6.2.26 (core)",
"@oclif/plugin-not-found 3.2.44 (core)",
"@oclif/plugin-plugins 5.4.34 (core)",
"@oclif/plugin-search 1.2.22 (core)",
"@oclif/plugin-update 4.6.33 (core)",
"@oclif/plugin-version 2.2.25 (core)",
"@oclif/plugin-warn-if-update-available 3.1.35 (core)",
"@oclif/plugin-which 3.2.31 (core)",
"@salesforce/cli 2.79.4 (core)",
"apex 3.6.8 (core)",
"api 1.3.3 (core)",
"auth 3.6.98 (core)",
"data 4.0.16 (core)",
"deploy-retrieve 3.20.6 (core)",
"info 3.4.41 (core)",
"limits 3.3.47 (core)",
"marketplace 1.3.7 (core)",
"org 5.2.38 (core)",
"schema 3.3.52 (core)",
"settings 2.4.18 (core)",
"sobject 1.4.50 (core)",
"telemetry 3.6.35 (core)",
"templates 56.3.39 (core)",
"trust 3.7.67 (core)",
"user 3.6.10 (core)"
]
}
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.
Thanks @geoffswift, I am seeing the same issue on mine. I will get a ticket created to look into this issue!
This issue has been linked to a new work item: W-18067034
I'm happy with the fix. I don't need my workaround any longer.