"What does this teach us? Well, it teaches me to do more diverse tests when doing destructive operations. It also should probably teach something to Vimeo and to my contractor but I doubt it will (and yes, the upload for some reason is still manual to this day. Go figure!)" So you wrote bad code, didn't test it properly, ran it on production on the Friday before a release and are blaming Vimeo and [name redacted]? An…
I Accidentally Deleted 7TB of Videos Before Going to Production
171–180 of 362 posts
Re: I Accidentally Deleted 7TB of Videos Before Going to Production
#172This is one of those times that even if you don’t use a fully functional language, trying to make as much of your program logic pure functions would be helpful. It also makes it more testable. Instead of putting the delete call right in the loop, split it into four functions. function getAllVimeoVideos() function getAllDbVideos() function getVideosToDelete(vimeo_videos, db_videos) function deleteVideos(videos_to_dele…
Re: I Accidentally Deleted 7TB of Videos Before Going to Production
#173The root of this particular issue was Vimeo's failure to do this migration for their customers. Vimeo OTT has a codebase written in Rails, whereas the main PHP application is written in PHP. At the time Vimeo acquired Vimeo OTT's codebase, the Vimeo OTT codebase was small — around 10,000 lines of Ruby. Rewriting that codebase inside the Vimeo PHP application would have been a tough technical challenge for the all-Rub…
Yes and No. At the end of the day, you as a business have to insulate yourself from your infrastructure provider.
Re: I Accidentally Deleted 7TB of Videos Before Going to Production
#174Earlier quoted context omitted.
Deleting * may not be though. Your selection needs to be idempotent.
idempotency means that f(X) = f(f(X)). Modifying the X inbetween is not allowed. Is there really an initial environment where rm * ; rm * ; does something different than rm * once?
if * expands to the rm binary itself, maybe.
Re: I Accidentally Deleted 7TB of Videos Before Going to Production
#175Earlier quoted context omitted.
there's an argument that the best people around are the people who have already (or almost) made some big mistakes. I have made a couple of huge ones - luckily I kept my job
When interviewing candidates I always enquire about their professional mistakes. Their reply often is the decider between hiring/rejecting. I want to have colleagues who admit fault, be truthful about actions which lead to the issue, and learn from it. The learning includes organisations perhaps putting additional measures in place to prevent future issues. One candidate told of a story how he was On-Call early in hi…
Re: I Accidentally Deleted 7TB of Videos Before Going to Production
#176What negativity and arrogance in the comments here. Jeez, it's like no one HN ever made a mistake, a bunch of 10xers ninja programmers here. Please read this: >I also want to preface this whole post by saying that I'm a Junior Developer with less than one year of actual experience. Some of the things that might seem obvious to some might not be so for me, thanks! It's just some kid sharing a mistake they made and own…
I have multiple years of experience than this man and still I could *very* *too* *easily* make a 7Tb mistake (or likely more :P )
Re: I Accidentally Deleted 7TB of Videos Before Going to Production
#177What negativity and arrogance in the comments here. Jeez, it's like no one HN ever made a mistake, a bunch of 10xers ninja programmers here. Please read this: >I also want to preface this whole post by saying that I'm a Junior Developer with less than one year of actual experience. Some of the things that might seem obvious to some might not be so for me, thanks! It's just some kid sharing a mistake they made and own…
Re: I Accidentally Deleted 7TB of Videos Before Going to Production
#178What negativity and arrogance in the comments here. Jeez, it's like no one HN ever made a mistake, a bunch of 10xers ninja programmers here. Please read this: >I also want to preface this whole post by saying that I'm a Junior Developer with less than one year of actual experience. Some of the things that might seem obvious to some might not be so for me, thanks! It's just some kid sharing a mistake they made and own…
I have done a lot of such blunders myself. Accidentally deleted my unchecked code and had to re-write everything from memory. I envy those who claim to do no mistakes at all.
Re: I Accidentally Deleted 7TB of Videos Before Going to Production
#179> but at the time the code seemed completely correct to me It always does. > Well, it teaches me to do more diverse tests when doing destructive operations. Or add some logging and do a dry run and check the results, literally simple prints statements: print("-----") print("Downloading videos ids from url: {url}") print(list of ids) ... ... ... # delete() dangerous action commented out until I'm sure it's right print…
As they say, measure twice, cut once.
Don't feel bad, I think every professional in IT goes through something similar at one time or another.
Re: I Accidentally Deleted 7TB of Videos Before Going to Production
#180Earlier quoted context omitted.
I'd hire this guy if only being for this frank about his mistake. He owned it and that is what I would look for. After deletion, what should he have done? Postpone the go-live? That's often not a a cost-effective option. As for a risk-analysis the worst what could happen was deletion of the remaining videos. I don't think that that makes big difference in this situation. And to do the right thing, you have to have th…
Owning the mistake would be fine if he did that - he did'nt. He blamed the company he was contracting for. That's a big no from me