- Madness. When I started using gdb in C it was lifesaver to find any runtime errors in my code. Coming from what is the shit of C compilation and runtime errors it saved what would effectively be hours of inserting printf statements to find the error. - It depends how well a language specifies where the runtime error is occuring. I just get “segmentation fault (core dumped)” as my runtime error which could mean any for loop or iterattive sequence in my program. 
- Extremely helpful debugging race conditions 
- To me logging combined with a quick compilation has a good flow to it. Causes you to consider what you want to see and doesn’t change the workflow if multiple stacks are involved. 
- printf(“here”)printf(“here1”)- printf(“here2”) - This is the way Although I also like: 
 File 1:
 print(0.1)
 print(0.2)
 File 2:
 print(1.1)
 print(1.2)
 …- Minimal c+p+e effort 
- Too hard to find in a busy log. - console.log(‘===== here1’) - have been there though I first try - printf(“HERE1”) 
 
 
- Can somebody reupload the image at a non-feddit.org host? Feddit is incredibly annoying in that it geoblocks most of Asia. - There you go  
- Seems to be blocking me too, in France. 
 
- As someone who knows how to use a debugger, I can say for sure that log debugging is fine and often my first approach. If you have a good mental model of the code and the issue, it’s usually just 1-2 logs to solve the problem. 
- I never felt a need to do it some other way 
- Meh - alert(“here”);is better- Not sure why you would say that. An alert() does not show you where in the code the alert was called from. A console log would show you. - There was a time when there was no console.log in javascript. Oh and browsers didn’t even have developer tools. - I remember those days. My comment still stands, I don’t know how your new reply explains why alert() is better in any way, shape or form. 😅 - Oh, it’s a joke with a touch of irony. Maybe even sprinkle some sarcasm in too. - Gotcha. It wasn’t clear to me but fair enough 👍 
 
 
 
 
 
- Old school. Also the flip side: - sudo tail -f /<path to server>/error.log
- I don’t use the debugger. I just write perfect code. - /s 
- Goodluck to use debugger on client side where only bug happens 
 
- It’s like the real life kraken, I’ve never seen it but the name causes dread. - This is what peak performance looks like: - console.log("before dothething"); let r = dothething(); console.log("after dothething"); console.log(r);- Hey how’d you get your hands on my code 
 
 
- Honestly I use debugger when I have to go deep into some library’s bullshit code. My stuff should be stable clean and understandable enough to quickly see what’s happening with console log. - If I were to find myself needing debugger all the time with breakpoints and all this shit, it means shits has gone sideways and we need to back up and re-evaluate the code. 
- I am guilty of this but for a different reason: setting up debugging for clis in rust is hard - I love the debugger. I use it all the time I can. But when debugging cli it’s a pain as you need to go back in the launch.json file, remake the argument list, then come back to run debug, find out why tf it doesn’t find cargo when it’s the PATH… again, then actually debug. - I don’t feel at all guilty of doing this. Whatever works. Usually nothing is so complicated that I need to debug properly, instead of just inspecting some value along the way. - In fact, if it gets the bug resolved, it is—effectively—debugging. 
 






