How can I debug MEAN applications

Debugger: Important tools for troubleshooting software

There is no such thing as perfect software without errors, which makes daily optimization practically indispensable. The big problem is often not at all faulty processes in the program sequence, but rather in the exact root cause to make out for it. Even an incorrectly placed parenthesis or an incorrectly used operator can cause a program to no longer work properly. With hundreds or even thousands of lines of code, the manual search - character by character - would offer little chance of success. For this reason, modern debuggers not only provide information that a problem has been detected, but also detailed information on the type of error and often about in which line of code he can be found.

Debuggers typically work Step by step through the respective program code. For this purpose, so-called Breakpoints (English breakpoints) defined. The debugging tool recognizes these points and can use them to stop the execution of the software at precisely these points. This gives developers the following two options:

  • It is possible that exact state of the program at this point in time to investigate. For example, it is very easy to check whether all integrated variables have output the expected values.
  • It is possible that Play the program from the respective breakpointto isolate any problems or sources of error.

The breakpoints do not necessarily have to be fixed: Many debuggers allow the Linking breakpoints to individual conditions. In this way, the program can also be stopped under certain signs. For example, if a loop runs 20 times correctly and a program error only occurs on the 21st run, the debugger can use a corresponding condition go straight to the problem. The previous, uneventful loops do not have to be run through again.

Other functions of debuggers include the Inspection of data such as the contents of variables, memories or registers as well as the Modification of memories like the main memory (working memory) or the processor register.