4 ms·
Ask HN: Do you tiptoe through your codebase like a minefield?
Is your codebase a frightening, brittle mess of dangerous interactions likely to collapse with any little touch, that you need to slowly and carefully tiptoe through like a minefield?
Or is a well organised, robust, structured code base that you can fly through and make changes at will?
- SEJeff 12y agoA mix of both (depending on time constraints)... with a lot of unit tests so refactoring it is part of life, and not a part I'm particularly afraid of. I go for the well structured approach, but you don't always have the luxury of time unfortunately.
- adamconroy 12y agoIt is well organised, robust, structured, with lots of unit / integration tests. I still tiptoe though, because in my experience over-confidence is a recipe for disaster.
- edoceo 12y agoI maintain a PHP app originally by a no longer present Chief. No framework, no MVC style separation of code. Minimal tests via Selenium. Its fragile. Upgrades or new features require lots of work, new more split code. We are in process of gradual rewrite - ETA 2018. Makes money but moves like a tortoise. A second one uses a little custom framework. We have more test cases for this one so we can mash through it w/o much concern. The total codebase is less than 200k lines (excluding framework). We can move fast but this makes little money A third has 4 devs, uses a common well known framework and each dev writes one test case a week (our test process is gamified). Makes good money and we can move pretty quick but have a methodical Work, Test, Beta, Live process too.
- phazmatis 12y agoI've inherited a few minefields. I can see how they weren't always this way. Some very smart people designed the project, and then a dozen or so engineers came through and, failing to fully understand the project structure, made their additions/modifications in totally harebrained ways. The fault lies with the original developers, who failed to create a robust, understandable codebase (no tests, no documentation, zero code comments(!)).