15

Colleague while reviewing my latest commit.
Him: Hey, RemusWasTaken, why did you leave this debug log in here?
Me: That function won't work unless I leave that line exactly there.
Him: It can't stay, come here so we can fix it.

Three hours of debugging later, this Friday afternoon.

Him: Okay, I give up. Let's leave it there for now.
Me: I did the same thing yesterday. Time well spent.

Nodejs is weird sometimes, or we are incompetent devs.

Comments
  • 1
    Does your code (or one of the libraries) contain some stupid (maybe native) io-buffering or multithreading shit?
  • 1
    @24th-Dragon I honestly don't know. I will probably slap myself when I fix it but I don't know right now.
  • 3
    @metamourge No multithreading, the logging is done with a library that logs to console and to files too but we couldn't trace it back to problems with it. It just won't work. I will continue next week, I am done, I left earlier because of it today. xD
  • 0
    Does your code load something from a file or network?
    If you can fix the problem by removing the log line and adding a small, manual delay, it's definitely related to asynchronous shit.
  • 0
    Did you try a sleep () instead?
    Sounds like some asynchronous stuff is happening, and the logging might give it just enough time to finish...
Add Comment