I remember a while ago (probably a year or two), my sister brought her computer over to my family’s house and thrust it at me. “It’s not working.” Was her wholly unhelpful description of the problem. Being used to this sort of treatment, I pressed the power button to begin troubleshooting. Almost instantly, the screen came to life and displayed nothing else but a missing drive icon. “Looks like a failed hard drive.” Was my response. “You backed up, right?” Of course she hadn’t. Luckily, by analyzing the hard drive from an external source, we were able to recover all of her important information. This was a lesson to me, always back up. Your computer could fail when you least expect it.
Or at least, I thought I learned a lesson. It was eleven o’clock the other night when I was testing out the uninstall function of my new program. It was alllllmost ready for release, 99% done. Just had to get the uninstallation feature correct. Everything was working perfectly. And then I did what no developer should ever do (apparently). Ran it on my main computer (production). As a developer/coder, all sorts of crap can always go wrong, so you should always have a layer of protection between programs and your main working computer. Going with that, you should never test on production (the main server you use for anything, company-wise or not). I ran the program, and everything looked great. Now time to test the uninstallation function. I went to the apps list on Windows, and confidently clicked “Uninstall”. My app, as planned, requested admin permissions. I clicked “Yes” without a second thought. And waited.
Nothing happened. So I clicked uninstall again. Same result. That’s odd. I thought to myself. I’ll check the code. I opened up File Explorer to see that half the folders in my C: drive were missing. …What? Was my first thought. I backed out to “My Computer” view to find that I had an extra 500 GB of space available to me that had been freshly freed up not 10 seconds ago. My hand shakily moused over the Recycle Bin, praying that the files would be there. But no. A quick Google search later proved my suspicions correct, and that my code bypassed the Recycle Bin. I still have no idea what happened, but the deletion of my files was so severe that as I was powering down the computer to try and save as much data for data recovery later, Windows was throwing errors about being unable to find critical system files and .dlls.
My guess as to what happened? Actually not sure. You can bet I’m going to post an update when I figure it out though. The data recovery program I’m using says that it’s gonna take 10 more hours at least for just my Documents folder, though. Lesson learned. Always keep backups.
My Patreon | My Website