1. A computer system for diagnosing an error associated with a software, the computer system comprising: one or more processors, one or more computer-readable memories, one or more computer-readable tangible storage medium, and program instructions stored on at least one of the one or more tangible storage medium for execution by at least one of the one or more processors via at least one of the one or more memories, wherein the computer system is capable of performing a method comprising: receiving a stack trace associated with the error; fetching a source code associated with the received stack trace; parsing the fetched source code associated with the received stack trace; generating an abstract syntax tree (AST) based on the parsed fetched source code; inserting at least one logging call into the generated abstract tree; and recompiling the fetched source code based on the generated abstract tree with the at least one inserted logging call.