Coffeehouse Thread

46 posts

what do you do when you can't find the bug?

Back to Forum: Coffeehouse
  • User profile image
    harumscarum

    So what creative things do you do when you have unleashed all your fury unsuccessfully at finding a bug?

  • User profile image
    TommyCarlier

    I go to the bathroom. I've solved many bugs because the solution unveiled itself when I was sitting on the toilet, not thinking about the problem.

  • User profile image
    ScanIAm

    TommyCarlier wrote:
    I go to the bathroom. I've solved many bugs because the solution unveiled itself when I was sitting on the toilet, not thinking about the problem.


          "The Throne of Infinite Insight(tm)"



    I usually get decent ideas on how to solve a problem when doing something else (showering/biking/etc.), but for actual bugs you just have to keep at it Sad

  • User profile image
    Cybermagell​an

    I tear apart the app function by function, comment out what's not neccesary and put trace statements wherever the bug is.

  • User profile image
    Minh

    There are levels of escalation:

    1) kick a beach ball around
    2) walk around the office
    3) go to Star Bucks & get a cup
    4) take a walk around the block
    5) go home

  • User profile image
    harumscarum

    Well went to the bathroom for a while but got distracted because there was a sign inside the stall that said not to flush paper towels. So I was then thinking of a scenario of why you would carry paper towels from the sinks over to the stalls to the flush. Then I begin wondering why some people have issues making it in to the toilet so to speak. I then wondered what some peoples home bathrooms must be like or maybe they just don’t have enough respect to take a little more caution.

    So then I took out the majority of code I was having problems with and thought I was close but then was defeated miserably. 

    So now I will search for a beach ball to kick around the office walking to starbucks around the block.....actually Im just going to go home.

  • User profile image
    amotif

    At the point where I'm frustrated enough to give up and go home I, er, give up and go home, banishing the problem from my head. Often by the time I'm a block away from the office I've found the piece of the puzzle I'm missing. Usually I realize it's because I'm lost in a million details and lost sight of the bigger picture.

    BTW, it can't be a pretend "I'm going home hoping to solve the problem unconsciously." It has to be a serious "Forget it, I hate computers--I'm going home." Tongue Out

  • User profile image
    ScanIAm

    I used to work for a guy who wrote MASM code (interrupt code for modems).  Anyway, we had another employee who was, to put it nicely, kind of dim.  We'll call him Newman.

    So whenever my boss got stuck, he'd call Newman into his office and start describing what the piece of code was supposed to be doing.

    Newman would ask "Why?".  Repeatedly.  So my boss would have to go into greater detail and in the process, he'd either figure out the issue or at least discover some new ways to come at it.

  • User profile image
    jason818_25​3.33

    some times im afraid i might be that Nimrod err, Newman.

    I cry!

    Edit:  I Cry
    Edit again: isnt crying like, kind of a creative solution? i didnt come up with it. but i kind of wish i had, because then maybe i would re write the code to insert balloons or something fun like that. then again, maybe i wouldnt. i dont know

  • User profile image
    Rossj

    Minh wrote:
    There are levels of escalation:


    5) go home


    Where you are guaranteed to come up with the answer 59 minutes into a one hour commute. Happens to me almost daily.

  • User profile image
    Charles

    Drink and smoke.
    C

  • User profile image
    JosephSpaur - MSFT

    Minh wrote:
    There are levels of escalation:

    1) kick a beach ball around
    2) walk around the office
    3) go to Star Bucks & get a cup
    4) take a walk around the block
    5) go home


    Oddly enough, I'm having one of those days and I've done the following:

    1) Thrown a football up and down the hall
    2) walked around outside
    3) drank a soda (oh man...i haven't had one in a few weeks and wow!)
    4) banged a golf ball on my desk until my office mate got annoyed
    5) surfed channel 9
    6) thinking about going home.

  • User profile image
    Harlequin

    I'll say one thing nobody else has.

    ...work late...

    Cool

  • User profile image
    DoomBringer

    I'm insane, so disregard, but I drill down into the thing deeper and deeper.  Something not working quite right?  Single step each line (and jump into everything).  If that doesn't help, I'll check the disassembly.

  • User profile image
    kettch

    Harlequin wrote:
    

    I'll say one thing nobody else has.

    ...work early...



    Fixed. Tongue Out

  • User profile image
    Massif

    It depends on the bug Big Smile

    Generally though I seriously abuse the debugger, like enabling first-chance exceptions for everything (of course, that only works if you're using or getting an exception.)

    Then there's plan B - talk to someone else about the problem, this works because 80% of the time you're talking it through and suddenly slap your head with the realisation that you know what's causing it. The rest of the time you've got help with the problem.

  • User profile image
    blowdart

    What bugs? Geez you guys just aren't 3l1t3 enough.

  • User profile image
    Tensor

    WHine. Moan. Complain. (I need to watch my language). Go home. Have a strange dream....

Comments closed

Comments have been closed since this content was published more than 30 days ago, but if you'd like to continue the conversation, please create a new thread in our Forums, or Contact Us and let us know.