When you work with software developers, especially those with less experience, it’s virtually guaranteed to hear one of them utter a version of the above expression when someone presents them with a situation they think is impossible (or more likely, improbable) to happen in the program they’ve written. Now, the great thing about software is that it’s mostly deterministic – if something strange happens, it’s very likely caused by a bug in the code rather than some unexplained cosmic coincidence. I’ve written about debugging in general before, so I’d like to focus on a set of bugs specifically caused by subsystems.
Hardware/OS/Compiler Programs don’t run in isolation. They depend on many subsystems to function. Obviously, you need a computer and a network connection. Your program also needs to be converted into a form the hardware/operating system combo can run, through the use of a compiler or interpreter.
Libraries Next come the libraries. Nowadays, it’s rare for anyone to write code entirely from scratch, thanks to the vast array of freely available libraries that cover tasks from the simplest to the most complex. Just as your program has a version, the libraries it depends on also have their own versions. Fortunately, there are useful programs called package managers that automatically download and install the correct library versions your program needs.