From efac5fe0358229069b1a8f1ab1d96067f59fd483 Mon Sep 17 00:00:00 2001 From: Andy Ko Date: Tue, 30 Apr 2019 11:27:43 -0700 Subject: [PATCH] Added paragraph about impact analysis. --- debugging.html | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/debugging.html b/debugging.html index adca212..b34a1ce 100644 --- a/debugging.html +++ b/debugging.html @@ -98,7 +98,18 @@

Fixing defects

-

Once you've found the defect, what do you do? It turns out that there are usually many ways to repair a defect. How professional developers fix defects depends a lot on the circumstances: if they're near a release, they may not even fix it if it's too risky; if there's no pressure, and the fix requires major changes, they may refactor or even redesign the program to prevent the failure (Murphy-Hill et al. 2013). This can be a delicate, risky process: in one study of open source operating systems bug fixes, 27% of the incorrect fixes were made by developers who had never read the source code files they changed, suggesting that key to correct fixes is a deep comprehension of exactly how the defective code is intended to behave (Yin et al. 2011).

+

+ Once you've found the defect, what do you do? + It turns out that there are usually many ways to repair a defect. + How professional developers fix defects depends a lot on the circumstances: if they're near a release, they may not even fix it if it's too risky; if there's no pressure, and the fix requires major changes, they may refactor or even redesign the program to prevent the failure (Murphy-Hill et al. 2013). + This can be a delicate, risky process: in one study of open source operating systems bug fixes, 27% of the incorrect fixes were made by developers who had never read the source code files they changed, suggesting that key to correct fixes is a deep comprehension of exactly how the defective code is intended to behave (Yin et al. 2011). +

+ +

+ This risks suggest the importance of impact analysis, the activity of systematically and precisely analyzing the consequences of some proposed fix. + This can involve analyzing dependencies that are affected by a bug fix, re-running manual and automated tests, and perhaps even running users tests to ensure that the way in which you fixed a bug does not inadvertently introduce problems with usability or workflow. + Debugging is therefore like surgery: slow, methodical, purposeful, and risk-averse. +

Further reading