3 ms·
I worked on a 20 KLOC app of mine yesterday that has neither static type decls or unit tests and yet is AFAIK bug free. This has been the rule and not the excep
by mkramlich 16y ago
I worked on a 20 KLOC app of mine yesterday that has neither static type decls or unit tests and yet is AFAIK bug free. This has been the rule and not the exception in my experience. So I prefer to not have them since in the general case they are not needed and just add clutter and drag.
- cabacon 16y agoI prefer to think of it as having bugs you just don't know about yet. Does anyone use the app besides you?
- mkramlich 16y agoGood perspective, thanks. And yes, many users other than me. Another way of looking at it though is to say if a bug has never been encountered that arguably it is not actually a bug and/or it doesn't matter. Anti-Heisenbug? :)
- kragen 16y agoHow long ago did you fix the last bug? That's probably a good estimate of how long you'll go before you fix the next one.
- mkramlich 16y agoBugs can exist within a coding session. I consider that a normal part of the development effort. You think of some change you want to make. You make it. If you discover you made a typo or overlooked some issue and thus it has caused a bug, during your dev-testing, you fix it. Once the desired change is done, working as intended, with no bugs, that change-sprint is done and commited to your VCS. Then you end the dev session or advance to the next desired change. The key is that when your dev session ends, and when you are just wearing the user's hat, there should be no bugs. In my experience, bugs can be found usually quickly and easily within the same coding session that introduced a new feature, while the code and your recent change are all fresh in mind, and you are in The Zone. That was a good heuristic you suggested, but I think it applies to situations where a bug survives beyond the end of a development session, accidentally.
- kragen 16y agobugs can be found usually quickly and easily within the same coding session that introduced a new feature, while the code and your recent change are all fresh in mind, and you are in The Zone That's probably true for 99% of bugs. But every time you say "no bugs" I'm inclined to interrupt and say "you mean, no known bugs!" There are probably large codebases without bugs; some or all of: qmail, some implementations of cryptographic algorithms, seL4, and some versions of the Space Shuttle in-flight software. But they're very rare. Maybe at some point every single one of the above codebases will have a bug found in it.