479
top 24 comments
sorted by: hot top controversial new old
[-] Solemarc@lemmy.world 92 points 1 month ago

My favourite is always;

Lemme quickly write this test, it passes great, if I make this little change it'll fail. It's still passing, damn.

[-] dan@upvote.au 58 points 1 month ago

The worst is when you expect an existing test to fail, but it passes, and it turns out the test wasn't actually properly testing the code. Fixing the test finds a bunch of broken edge cases.

[-] TunaLobster@lemmy.world 44 points 1 month ago

Then you ask questions about what the past person could possibly have been thinking. You wonder what logic path brought them to create the code this way. You check git blame. It was you.

[-] sbv@sh.itjust.works 22 points 1 month ago

Debugging. It's a whodunnit where the victim, murderer, and investigator are all you.^(apologies to Filipe Fortes)

[-] Balthazar@lemmy.world 63 points 1 month ago

It's always scary when it compiles without errors the first time. Then you just know there's a logic bug or corner case in there somewhere.

[-] IsoSpandy@lemm.ee 4 points 1 month ago

It's always a logic bug that you will find the day after you forgot about how the code works.

[-] Semi_Hemi_Demigod@lemmy.world 56 points 1 month ago

Congratulations your code will now be in production for the next hundred years.

[-] marlowe221@lemmy.world 22 points 1 month ago

Nothing is temporary. Every script, patch, application, and duct tape MacGyver/Scotty inspired fix I’ve ever written will run for eternity….

[-] dan@upvote.au 22 points 1 month ago* (last edited 1 month ago)

The first "temporary hack" I ever wrote for my current job (~January 2014) is still in the codebase.

[-] 0laura@lemmy.dbzer0.com 42 points 1 month ago

if you didn't intend for it to work and it's working then it's not working as intended

[-] NocturnalMorning@lemmy.world 19 points 1 month ago

Corollary, what moron wrote this...oh, i did.

[-] RagnarokOnline@programming.dev 9 points 1 month ago

Of course I know him: he’s me!

[-] Anticorp@lemmy.world 8 points 1 month ago

One time I stayed up late trying to fix a really complicated problem that I couldn't figure out. I was drinking. I got really drunk and fixed the problem. In the morning I couldn't figure out my own code. I had no idea what I wrote, or how it worked, but it did work. I just left it since it was apparently above my ability to fix.

[-] joyjoy@lemm.ee 14 points 1 month ago

Better ship it. It works after all.

[-] Anticorp@lemmy.world 10 points 1 month ago

This stops being shocking as you gain more experience.

[-] MonkderVierte@lemmy.ml 8 points 1 month ago

Still no usable code tho, because usable code is maintainable.

[-] WalrusDragonOnABike@lemmy.today 7 points 1 month ago

Something's broken, Something's failing, rotting!

[-] AwesomeLowlander@sh.itjust.works 6 points 1 month ago

MFW I hook up a Factorio spaghetti section to inputs and it works the first time.

[-] Awkwardparticle@programming.dev 5 points 1 month ago

"You know that temp shitty load balancer you wrote on your second month to get things up again. We still use it to this day." My boss last week.

[-] rockSlayer@lemmy.world 5 points 1 month ago

It works as intended because you haven't integrated yet

[-] RedSeries@lemmy.world 5 points 1 month ago

Remember, every temporary solution is a permanent one! It's always spooky when it works the first time.

[-] luciole@beehaw.org 4 points 1 month ago

Break it, confirm it's broken, fix it back. Makes me feel better every time.

[-] nixfreak@sopuli.xyz 2 points 1 month ago

lol - isn’t that the truth

this post was submitted on 19 Nov 2024
479 points (97.4% liked)

Programmer Humor

19880 readers
169 users here now

Welcome to Programmer Humor!

This is a place where you can post jokes, memes, humor, etc. related to programming!

For sharing awful code theres also Programming Horror.

Rules

founded 2 years ago
MODERATORS