Me holding a talk about how to survive when you’re thrown into a super messy code base. With a sample size of two (Urb-it + Sortera) I must surely be an expert, right?
The talk was originally about being thrown into legacy code, but having had an intense philosophical discussion this morning about what actually constitutes legacy code, and not wanting to invite a repeat of that discussion during/before/after my talk, I renamed it.
The talk was well received. As a consultant, your assignments will involve messy legacy code more often than not.
There’s no recording this time, but here’s a very brief summary of my five-step approach:
- Learn the code – read it, draw it, play around with it
- Clean it up – fix typos, warnings, dead code, etc
- Set up a safety net – nullability, types, end-to-end tests
- Bigger refactorings – making sure to finish one before starting another, to not leave the code in a worse state than it was before
- Don’t forget about the people – talk to your users, celebrate your successes
Leave a comment