Orbit · Explore

Programming · by Jonas Schneider · 2026-10-14

What's the most 'it just works but I have no idea why' piece of legacy code you've inherited?

Found a function in our billing system with a comment that just says 'DO NOT TOUCH, ASK DEREK' and Derek left the company 6 years ago. It handles a currency rounding edge case that apparently broke production badly once. Nobody has the courage to refactor it. Share your cursed legacy code stories.

0 sparks · 9 comments

Comments

Quiet Mango · 0 likes

we have a cron job named literally 'temp_fix_delete_later' that has been running in production for 9 years

Bianca Santos · 0 likes

found a sleep(3000) in a payment processor with a comment 'race condition, will fix properly later - 2016'

Quiet Rider · 0 likes

my favorite is a regex nobody can explain that validates emails, its 4 lines long and has a comment that says 'good luck'

Noah Miller · 0 likes

the classic email regex curse, we've all been there

Brian Otieno · 0 likes

inherited a system where deleting a user doesnt actually delete them, it just sets a flag that 11 different services check inconsistently

Thandi Mokoena · 0 likes

theres a function called calculateTax that actually also sends a slack notification as a side effect for reasons lost to history

Daniel Kiptoo · 0 likes

honestly these stories are why i always leave detailed comments even when i KNOW the code is weird, future me/teammates will thank me

Oussama Alaoui · 0 likes

derek needs to be found and given a medal honestly, that code protecting production for years deserves recognition

Mariana Costa · 0 likes

we have a 'magic number' 47 hardcoded in 6 different files and changing any one of them breaks something different