Read the screenplay: FANNIEGATE — $7 trillion. 17 years. The biggest fraud in American capital markets.
#31🚀 DeploymentPainful

Deploying to Production on Friday Afternoon

Friday deploys turn weekends into war rooms.

What Happened

It was 4 PM on a Friday. The client wanted the feature live before Monday. I pushed a Flow change and a trigger update to production. The Flow had a different field mapping than prod and started nulling out a critical field on every Contact update. By Saturday morning, 3,000 Contact records had blank Email fields. I spent my entire weekend doing a data restore from a backup export I almost didn't have.

The Wrong Way

# 4:47 PM Friday
sfdx force:source:deploy -p force-app/main/default/flows,force-app/main/default/triggers \
  -u production --json
# "Ship it, what could go wrong?"
# Answer: everything

The Right Way

# Deploy Tuesday-Wednesday with a plan:

# 1. Run all tests in production validation (no deploy yet)
sf project deploy start -d force-app -o production --dry-run --test-level RunLocalTests

# 2. Export backup of affected objects
sf data export bulk -o production -q "SELECT Id, Email, FirstName, LastName FROM Contact" -f contacts-backup.csv

# 3. Deploy with RunLocalTests during business hours
sf project deploy start -d force-app -o production --test-level RunLocalTests

# 4. Run smoke tests immediately
sf apex run -o production -f scripts/smoke-test.apex

# 5. Monitor for 2 hours before considering it done

The Lesson

Never deploy on Fridays. Always have a backup. Always run a validation-only deploy first. Your weekend is worth more than a Monday deadline.

Don't make this mistake.

Hire someone who already did.

View Consulting →

Enjoyed this? Get more like it.

Glen's Musings — AI, investing, and building things. Occasional. Free.

More Deployment Mistakes