📢
20
c/fix-my-code-friday•park.irispark.iris•1mo ago

Debugged a loop that ran 10,000 times instead of 100 in my Python script at 3am on a Wednesday, cost me my whole dataset

I was sitting in my laundry room with a laptop on the dryer, watching my results pile up wrong for 45 minutes before I noticed the range() call said 10000 instead of 100, and by then my CSV file had 9,900 extra rows I had to manually clean out, so what do you guys do when a sneaky off-by-multiple error wastes your time like that?
2 comments

Log in to join the discussion

Log In
2 Comments
maxb46
maxb461mo ago
Backup next time before hitting run, rookie mistake lol
7
kevin_hernandez83
rookie mistake lol" bro @maxb46 this guy straight up deleted his whole project folder?! no backups at all?? thats wild i would be sick for a week
6