Data loss after power outage #11406
Comments
This is a very interesting behavior you are pointing out, because the file you are editing should not necessarily be written to unless you save. Would you try to simulate force exiting Atom while editing and try to reproduce this problem? You may be able to follow a guide like this one to setup xkill on a kaybinding. I very much wish to narrow this problem down, and test it in safe mode. |
A colleage of mine has had the same problem and therefore switched to another editor. I am about to do the same as I cannot rely on Atom when a power cycle occurs. I have had this enough times that I don't have to try it again. Use the above setup, work in a file, let the power run out in such a way that the device is not going into hybernation or anything. Restart and your file is messed up beyond recognition. |
Can't reproduce on OS X 10.11.4 |
Had the same problem on Windows 10, the system crashed with a Blue screen of death, and the file which I was editing is now corrupted. So, frustrating and annoying. |
Related feature: #11828 |
Yes. In case the recovery service doesn't manage to restore the corrupted file automatically, there's should always be a backup file that you can find under The feature has already been shipped in I am going to close this for now, as #11828 was purposefully designed to address this kind of issues. Please, let me know if you encounter any other problems after trying out Thanks! |
Thanks. Please, make this fix appear in the release notes and give it some special attention because I know that some users have abandoned Atom because of this. In this way, you could win them back. |
hit by the same problem today. loosed two days of works... frustrating and annoying. didn't find any ~/.atom/recovery folder Version: Atom : 1.8.0 |
As mentioned above...this feature is only available in Atom 1.9.0-beta0 and higher. |
For informational purposes, why is atom temparily storing the file in a binary format in the first place? Better to leave the file untouched be store temp stuff in ~/.atom With a crash, I have to reconstruct which files I had open. Suppose these are several hundred files... |
I don't think Atom is intentionally storing files in binary format - where did you get that information? |
This is the only application out of dozens major applications having this side-effect. So perhaps it is not storing it binary, but the effect of a power cycle is disastrous. |
Unfortunately this remains a deal breaker. |
Just had this problem as well. Really messed up my work as I hadn't pushed to my git server in awhile. |
I also had the same issue. Is there any way to recover the binary file? I wasn't saving at the moment, so it was entirely unexpected. The atom recovery folder was also empty. |
I experienced a power surge and the file in the current tab (a config file, yay!) was corrupted. I could not recover the file. The recovery folder was empty. Ubuntu 15.10 |
Atom: 1.12.6 I just had a system freeze and restarted to find my file empty. I opened it in vim and nano, found it full of As far as I can tell the file saved successfully because I was using a build tool that detects changes. I saved the file and then the build tool started running, it froze before the build tool could finish and now the file is empty. The file isn't in Is there any chance of me recovering it? Here is the file for anyone interested |
Looks like this didn't get fixed by the recovery service. Reopening (/cc @as-cii). |
First of all, apologies to everyone for the inconvenience and thanks so much for the reports. This is an issue we take very seriously and it would be great if you could help us understand the circumstances in which it happens, so that we can reproduce it locally and fix it once for all.
@FallingSnow Interesting. After Atom successfully saves a file, it deletes it from the recovery folder. This makes me suspect that the underlying cause of the issue could be a third party package. Would you mind sharing which packages you had installed at the moment of the crash? We can go through them one by one and understand whether the culprit is among those or not. @PanderMusubi Have you been able to reproduce this more than once? If so, could you share with us all the packages you have installed, please? If I understand correctly, it happens when the system is powered off unexpectedly. Does the data loss occur when the system powers off during a save? Or does it happen consistently in response to a power outage, no matter what task Atom is performing? |
Yes, that is why I moved to https://en.wikipedia.org/wiki/Geany I work a lot in trains and occasionally run out of battery with this as a result. |
@as-cii In my case, the only corrupted file was the one in the open tab. The other tabs I had open were fine. It may be something with this auto-save plugin: https://atom.io/packages/atom-idle-autosave OR the default Atom auto-save plugin. |
You can get a list of all installed community packages by running |
I would also like to note that only the current tab was nulled out. The rest of the tabs were unaffected. Edit: Also, for anyone else, I was able to recover the lost file using |
Here is the result of
|
I don't think developers understand how much pain this can cause. It made me lay down in fetal position and cry. |
This is what I got now |
Facing same problem, going to switch ide |
Had this problem too. The file now has a bunch of 0s only. What is going on? No way to fix it now. |
I switched too, to VS Code . In places where you have power outages often or for longer time than one hour you can't use this IDE.. VS Code is great, never lost my files |
I think this just happened when restarting Atom due to updating a package. I now have 1480 zeroes (0x00) in the file I've been working on. The file is not in ~/.atom/recovery. |
Yeah, I just lost 8 hours of work and there's no file on I'm like super frustrated right now |
Ugh ... Same here. Files were saved, but computer froze. Restarted the computer and upon opening Atom I found all of my currently opened files are now just pages of zeros..... Zeros as far as the eye can see!! Jesus... ___ Is this a one strike rule? Is anyone switching to a different editor over this? I'm on Windows 10 too. |
This issue dates back to years ago and yet no Fix... , i switched from atom the moment this thing happened to me (3 yrs ago) |
Yes, also switched. Had this crash twice when I used all the power in my laptop battery. Could not have again loss of data. Used Atom for programming but switched back to full IDEs such as https://www.liclipse.com and https://www.spyder-ide.org |
Hi everyone, I just had the same problem and two days later I found most of my code in Cheers, |
Just had this happen. Windows memory management error led to bluescreen, and when I reopened I had a file of zeros. |
This happened to me too. Nothing in ~/.atom/recovery/ or using Windows file recovery. I love Atom but this is unacceptable behavior from an editor. I lost about two days of work as well. How is this still a bug after 3 years?! |
I’d recommend moving to Visual Studio Code. Microsoft acquired Gitlab a
while ago and my guess is that VS code will eventually overtake Atom. Also,
VS code is also on the Electron platform. I’ve been using it as my daily
IDE and have had zero issues with it. I use VS code on Ubuntu and Windows.
…On Tue, Nov 26, 2019 at 10:41 AM Hannah Crabtree ***@***.***> wrote:
This happened to me too. Nothing in ~/.atom/recovery/ or using Windows
file recovery. I love Atom but this is unacceptable behavior from an
editor. I lost about two days of work as well. How is this still a bug
after 3 years?!
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#11406?email_source=notifications&email_token=AAPSLP3CB5A6PIHQDC2QPUTQVU7T5A5CNFSM4CALNO5KYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEFGOOSQ#issuecomment-558688074>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAPSLP6EORLLEYWCIDV3FWTQVU7T5ANCNFSM4CALNO5A>
.
|
Hi. |
The main problem is that even you had your file saved, when there is power outage it will be deleted/nulled just because you had it open in Atom IDE ! |
Looks like Atom uses 'fs' Javascript module to do IO. It seems alright, but it is not atomic. Moreover, there are subtle uses like I have also found a similar issue in the VS Code bug tracker. I expected to see IO to be something like this @as-cii @rafeca @nathansobo @jasonrudolph |
If I remember correctly, this only happens if you have the "restore windows on reboot" feature ON but I'm not 100% sure on that. |
Just had this issue when my laptop battery slipped out while coding in Atom. ~.atom/recovery directory just has like 5 random files from the past several months, none of which are the one I needed. The file in question isn't even zeros or strange characters, it's just completely blank. I should have built a repository and been using git, but I thought I was still in the tinkering stage until the moment I realized how much I'd lost when App.JS got corrupted. Lesson learned. I'll use git even when tinkering...and switching to a more reliable editor ASAP. I love Atom, but am really disappointed with this issue. Was surprised to see this open issue going back all the way to 2016! |
Had the exact same issue. Clicked CTRL+S to save, in that exact moment the power went out. Destroyed file has the same size but is full of NUL characters. Uninstalling now. |
The 5th anniversary of this bug :D |
This just happened to me. Lost all my work. Uninstalling Atom, I can't have this happen again. |
Sorry to hear. Atom should show a warning each time you start it saying: beware, a power cycle while editing will corrupt your files. It should also have a link to this more than six year old issue. And there is no option to not show this warning again. Perhaps we can make a PR for this. PS This not a joke. |
To be honest I have been using VS Code for the first time today, and I'm a bit shocked at how much better it is for me than Atom. It seems to be a lot faster, and the default terminal is very good. I think this might have been a blessing in disguise to finally move away from Atom. |
Looks like Github is officially sunsetting Atom. Good riddance. Use something else as this damned bug has been around for as long as I can remember and it still hasn't been fixed. I use either Sublime Text or VSCode. Both superior IMHO. |
Lost all my data for the second time and yet still no solution for solving this issue or recovering my files. This should be a top priority for atom dev team. |
Yeah it's horrible man. The sick part is I would have still had my work if I didn't save. The main takeaway is to DELETE ATOM, everyone should delete atom. I honestly had to stop programming altogether when this happened because of my situation. I'm only just getting back into it. Ive been on this thread for at least 4 years and noone mentioned a work around. Delete it and tell everyone you know to delete it because the devs have officially abandoned it now in favour of commitments to vscode. The link to the sratement is above. Vscode is what I've moved to. It's got everything atom had and more as far as I can tell. One day I'll try to reverse that garbled file. 🤷♂️ |
Description
How to restore corrupted file after power outage.
This has happened three times in the past half year and now really disappointed (to say the least, sorry). But this is not the behaviour I expect from a quality editor. Cannot find via Google or issues in GitHub how to resolve this.
Steps to Reproduce
Expected behavior: [What you expected to happen]
That the file is never corrupted after a power cycle or the corrupted file is restorable. An editort should never be alowed to have this behaviour. At the moment of the power cycle I was not saving, only typing.
Is there any tool to run and get my original file back?
Actual behavior: [What actually happened]
I ended up with a corrupted file as described above.
Versions
Up to date Ubuntu 15.10 with
$ atom --version
1.6.2
$ apm --version
apm 1.6.0
npm 2.13.3
node 0.10.40
python 2.7.10
git 2.5.0
The text was updated successfully, but these errors were encountered: