- cross-posted to:
- programmer_humor@programming.dev
- cross-posted to:
- programmer_humor@programming.dev
console.warn() to differentiate what you’re looking for from the regular logs.
Nothing wrong with console.log.
deleted by creator
This is the way.
Yeah. Obviously that’s what console.debug() is for.
Sometimes there’s literally no other way (that I know of). When you’re debugging concurrency issues, stopping all time with a debugger just isn’t an option.
Yep, I’ve had times where the debugger was hiding the race condition that was the actual cause of my problem.
I guess, there’s technically nothing which dictates that a debugger has to work by stepping through a program. It could also present you some diagram of variable values changing over time. But yeah, gonna be hard to find a more useful representation than those values being interleaved with your logs, at least for most applications. I have heard of more advanced debuggers being used in gamedev, which makes sense, since logs aren’t nearly as useful there.
But yeah, given that most people think of the stepping debuggers, them being the default advice does feel emblematic of our industry still shying away from concurrency.
console.log("poop")
console.log(“here”) console.log(“here 2”) console.log(“here 3”)
Oh my console.log messages are so much better than that now… (that I started telling copilot to add them for me).
I sometimes write the (temporary) line number to get back to a suspect section quicker
Please stop leaking my code.