r/ProgrammerHumor • • Oct 10 '26

Meme weAreWizards

Post image
7.8k Upvotes

203 comments sorted by

View all comments

Show parent comment

1

u/LadyZaryss Oct 11 '26 edited Oct 11 '26

It is likely because the brief moment of CPU time consumed by the console.log is exposing that theres a race condition in your code somewhere. Replace the console.log with a wait/sleep/delay and see if it still crashes, if it does you have a race condition somewhere.

2

u/Prematurid Oct 11 '26

I figured it had to be something like that, but for my purposes it works as it is, so I decided to leave well enough alone. It is just a personal project that I use occasionally.

Still makes me laugh though.