this post was submitted on 22 Jun 2023
314 points (100.0% liked)

Programmer Humor

852 readers
5 users here now

Post funny things about programming here! (Or just rant about your favourite programming language.)

Rules:

founded 5 years ago
MODERATORS
 
top 16 comments
sorted by: hot top controversial new old
[–] Dirk@lemmy.ml 12 points 1 year ago

console.log("Does it happen here?")

[–] DonjonMaister@programming.dev 11 points 1 year ago (1 children)

Stage 4.5: console.log() everything.

[–] zqwzzle@lemmy.ca 7 points 1 year ago (2 children)

And then the logging fixes the subtle timing issue causing the problem.

[–] V699@kbin.social 4 points 1 year ago (1 children)

Race conditions are the worst

[–] zqwzzle@lemmy.ca 1 points 1 year ago

Good ol’ Heisenbugs.

[–] sickmatter@fedia.io 1 points 1 year ago

Especially if logging ends up spreading a global mutex around the log file.

[–] ShustOne@lemmy.one 4 points 1 year ago

As true as true can ever be

[–] Rhaedas@kbin.social 3 points 1 year ago (1 children)

I have some Excel VBA scripting that I've been on 1-4 for a while now, so there's a branch off of 4 that should be "fuck it, here's the workaround" or "that part isn't that important anyway, ignore it".

(it's actually not Excel that's the problem, it's the change to its call to IE that throws up a stupid security warning.)

[–] chaorace@lemmy.sdf.org 2 points 1 year ago

Oh my god this comment gave me an aneurysm

[–] z500@startrek.website 3 points 1 year ago

Every time that last part happens I have to check the proper spelling of Berenstain. I've had some that really seem like they should have been impossible lol

[–] PtitSerpent@kbin.social 2 points 1 year ago (1 children)

if (0 === 0) {
var_dump($test); die;
}

[–] tgxn@lemmy.tgxn.net 1 points 1 year ago

Ahhhhh, PHP.... 😭

[–] kriss0706@kbin.social 2 points 1 year ago

its funny i see this now, after spending 3 hours debugging D:

[–] randombit@lemmy.sdf.org 2 points 1 year ago (1 children)

One of the best pieces of advice I have ever gotten was to build diagnostics first. The time it takes to do will pay for itself 100X over the course of development.

[–] Celivalg@iusearchlinux.fyi 2 points 1 year ago

100% unit tests ftw

Hate making them, love them when they are here

[–] DarthYodaX@lemmy.sdf.org 2 points 1 year ago

My boss does 1 <--> 2 with us over most every bug any of us has ever found. Ticking time-bomb...

load more comments
view more: next ›