A very serious and difficult bug can make the career of an experienced professional programmer who has experienced a lot of stress. Going through this ordeal can be as traumatic as a serious physical injury, divorce, or family death.

Researchers studying the psychology of computer programming have determined a programmer’s mental mile when it comes to solving a difficult bug. These Stages resemble what is known as Kubler-Ross Stages of Grief (a model that describes five separate Stages of Grief and Grief (denial, anger, griefing, depression, and acceptance). Terminally ill patients are thought to go through these stages) for similar reasons. Like the sadness that comes with death, fixing a bug is a process that initializes an event, initially a denial of belief, that creates a mood of distress that gradually affects your mind. The result is that you will struggle to endure it, and eventually you will find a satisfactory outcome.

Knowing the stages of “fixing” helps us to survive and stay fixed, which eventually leads to… Turn off the results of all our bugs.

Stage one: Resistance

I am Skeptical or angry or Offended in this stage. Irritability Petulant.

1. Don’t ignore

Maybe this bug will go away quietly.

2. Mark “Not a bug”

Maybe it’s the user’s fault, or there’s a problem with the local configuration. Yes, I’m sure it is. It’ll be all right in a minute.

3. Just a glitch

I think it was just a glitch, it happened strangely once, it won’t happen again, it’s not quite clear why it happened, but it’s like our database or grid or browser or something had a few hiccups. It’ll be all right in a minute, I’m sure.

4. Hide.

I’m going to take a few sick days. Maybe they’ll pass it on to someone else.

5. Mark as “Changing Requirements”

You see, I did it on demand. If you want to change the behavior and the UI, you have to change the requirements. Maybe they’ll decide that’s it.

More information is needed

I can’t be sure this is a bug unless I see a specific error message in the error log.

7. Transfer to someone else

I investigated this bug and saw data in other modules that I could not understand, which was a big problem. I should pass this bug on to the people who developed that module. I can check that corner in my module, but the correct fix is in someone else’s module. It’s in another country anyway. I can’t see him.

Stage two: Acceptance

Status of this stage: Resigned. Defeated. Enraged Annoyed.

1. Accept it

All right, all right, all right! It’s my bug, and I’ll fix it.

2. Save this bug for last

Maybe I can find a new job before I need to fix this bug.

Haggle with your manager

Ok, you see, I can fix this problem correctly, but I need a month. That said, I could put a Band-Aid on the problem and that wouldn’t really fix it, but we could avoid user complaints and that would buy us a few days.

4. Mark a cheeky date for this bug

God, I hope that’s enough time.

Call waiting welfare

1. Recently sorted out 20G resources, including product/operation/test/programmer/market, etc., and Internet practitioners [necessary skills for work, professional books on the industry, precious books on interview questions, etc.]. Access:

  • Scan the code of wechat to follow the public account “Atypical Internet”, forward the article to the moments of friends, and send the screenshots to the background of the public account to obtain dry goods resources links;

2. Internet Communication Group:

  • Pay attention to the public account “atypical Internet”, in the background of the public account reply “into the group”, network sharing, communication;


Stage 3: Engagement and frustration

The state of this stage: Giddy Giddy. Light-headed. Nervous Nauseous.

1. Start investigating

I can handle this! I can handle this! With a little tweaking, a little attention, a little more caffeine, and a little more time, I can fix it.

2. Lost

Shit. This is ridiculous. I’m not making any progress. This code is a mess. It’s fucking amazing that such code compiles and runs, have I had a chance to figure out what’s wrong with it?

3. Hide again

Look, I’m sorry. I had to have my appendix removed. Again, yes, now that you mention it, I do have two appendices. Now I don’t have any. Are you happy? .

4. Make mean

Well, anyway, what did you expect? Want me to fix this BUG in an environment without an advanced debugger. What am I? Clairvoyant? I got a better debugger on my Commodore 64!

5. Fiddle-faddle

See if I try this? Kao, this is no good. How about this? Also not line. How about that? Shit, it just got worse.

6. Despair

I can’t fix this bug. I’m a terrible programmer. I’m so stupid. What am I doing in a place full of smart people? Sooner or later, they’re gonna know I’m bad, and then I’m done, and I’m done here.

7. Shame

My manager asked me why IT took me a month to fix a bug that could only be fixed in two days. To be honest, I don’t know how to read the log messages. I broke our compile script. Now, I’m afraid to ask others to help me, because it just makes me look more stupid.

8. Panic!

This is getting more complicated than I thought! And I began to feel that complicated things became simple… And I think the easy thing is to reorder half a dozen classes. Why did I clap my chest in front of my manager and say I could handle this?

9. Work through the night, away from friends and family

(Muttering to himself and cursing loudly)

Stage four: The pleasure of stupidity

The state of this stage: Grateful and Relieved. Awfully admire Yourself.

1. Wake up

Oh! I finally figured out how to fix it…

2. Write the right code

I’m a coding machine!

3. The test

Cattle! Pass a test. True cow! I passed another test. Depend! Some tests failed. That’s why…

4. Hide the test failure

This is a completely trivial test case anyway. No one will check it. It’s a pointless test.

5. Submit code

Oh, I’m awesome. Is there a pie in the kitchen to celebrate?

6. Close the bug.

I hear there’s a pie there to celebrate

Stage 5: Melee with completion

Nervous. Nervous. Superstitions Superstitious.

1. Someone is opening this Bug

A: really? They figured out you introduced another bug? Shit – that was just a minor case that never happened.

2. Fix previous fixes

Yes, I even checked if the employee’s age was an imaginary number, just in case I made a mistake.

3. Close the bug

Yeah, bitch, you’re shut down. Shut it all down. Don’t be upset anymore.

4. Promise never to do it again

5. Everyone realizes that you are now an expert in that module

Oh, no! Now they have given me three new bugs with that module

It doesn’t matter, now you just need to GOTO the first stage.

Besides, as a working programmer, you will experience this crap forever until you — die, retire, or get promoted to management.

(Full text)

Author: increasingly, blog: https://coolshell.cn/articles/18190.html