Atom crashed and my source file ended up blank

You know what probably I’m going to do is stage commits in terminal, so that if my Mac crashes, I can get it back there.

I am just so surprised to find this failure mode, since I’ve never heard of loosing all open file descriptors on crash. What the heck.

I suppose I’ll also be putting my folder inside dropbox for critical projects.

Just had this happen after a laptop crash. Here is my report:

  1. Mac OS version 10.13.6
  2. Atom Version 1.40.0
  3. Package List
$ apm list
    Built-in Atom Packages (93)
    ├── atom-dark-syntax@0.29.1
    ├── atom-dark-ui@0.53.3
    ├── atom-light-syntax@0.29.1
    ├── atom-light-ui@0.46.3
    ├── base16-tomorrow-dark-theme@1.6.0
    ├── base16-tomorrow-light-theme@1.6.0
    ├── one-dark-ui@1.12.5
    ├── one-light-ui@1.12.5
    ├── one-dark-syntax@1.8.4
    ├── one-light-syntax@1.8.4
    ├── solarized-dark-syntax@1.3.0
    ├── solarized-light-syntax@1.3.0
    ├── about@1.9.1
    ├── archive-view@0.65.1
    ├── autocomplete-atom-api@0.10.7
    ├── autocomplete-css@0.17.5
    ├── autocomplete-html@0.8.8
    ├── autocomplete-plus@2.42.3
    ├── autocomplete-snippets@1.12.1
    ├── autoflow@0.29.4
    ├── autosave@0.24.6
    ├── background-tips@0.28.0
    ├── bookmarks@0.46.0
    ├── bracket-matcher@0.91.1
    ├── command-palette@0.43.5
    ├── dalek@0.2.2
    ├── deprecation-cop@0.56.9
    ├── dev-live-reload@0.48.1
    ├── encoding-selector@0.23.9
    ├── exception-reporting@0.43.1
    ├── find-and-replace@0.219.0
    ├── fuzzy-finder@1.14.0
    ├── github@0.30.0
    ├── git-diff@1.3.9
    ├── go-to-line@0.33.0
    ├── grammar-selector@0.50.1
    ├── image-view@0.64.0
    ├── incompatible-packages@0.27.3
    ├── keybinding-resolver@0.39.0
    ├── line-ending-selector@0.7.7
    ├── link@0.31.6
    ├── markdown-preview@0.160.2
    ├── metrics@1.8.1
    ├── notifications@0.70.6
    ├── open-on-github@1.3.1
    ├── package-generator@1.3.0
    ├── settings-view@0.261.3
    ├── snippets@1.5.0
    ├── spell-check@0.75.0 (disabled)
    ├── status-bar@1.8.17
    ├── styleguide@0.49.12
    ├── symbols-view@0.118.2
    ├── tabs@0.110.0
    ├── timecop@0.36.2
    ├── tree-view@0.228.0
    ├── update-package-dependencies@0.13.1
    ├── welcome@0.36.9
    ├── whitespace@0.37.7
    ├── wrap-guide@0.41.0
    ├── language-c@0.60.18
    ├── language-clojure@0.22.8
    ├── language-coffee-script@0.50.0
    ├── language-csharp@1.1.0
    ├── language-css@0.44.0
    ├── language-gfm@0.90.6 (disabled)
    ├── language-git@0.19.1
    ├── language-go@0.47.1
    ├── language-html@0.52.3
    ├── language-hyperlink@0.17.1
    ├── language-java@0.31.3
    ├── language-javascript@0.132.0
    ├── language-json@1.0.4
    ├── language-less@0.34.3
    ├── language-make@0.23.0
    ├── language-mustache@0.14.5
    ├── language-objective-c@0.16.0
    ├── language-perl@0.38.1
    ├── language-php@0.44.2
    ├── language-property-list@0.9.1
    ├── language-python@0.53.3
    ├── language-ruby@0.72.17
    ├── language-ruby-on-rails@0.25.3
    ├── language-rust-bundled@0.1.0
    ├── language-sass@0.62.0
    ├── language-shellscript@0.27.12
    ├── language-source@0.9.0
    ├── language-sql@0.25.10
    ├── language-text@0.7.4
    ├── language-todo@0.29.4
    ├── language-toml@0.20.0
    ├── language-typescript@0.5.2
    ├── language-xml@0.35.3
    └── language-yaml@0.32.0

    Community Packages (33) /Users/cfischer/.atom/packages
    ├── atom-beautify@0.33.4
    ├── atom-dbt@0.4.4
    ├── atom-material-ui@2.1.3
    ├── autocomplete-tailwind@0.8.1
    ├── busy-signal@2.0.1
    ├── emmet@2.4.3
    ├── emmet-jsx-css-modules@1.0.0
    ├── fonts@3.5.0
    ├── formatter@2.12.4
    ├── formatter-tidy@1.0.1
    ├── goto-definition@1.3.4
    ├── highlight-selected@0.16.0
    ├── intentions@1.1.5
    ├── language-markdown@0.37.0
    ├── linter@2.3.1
    ├── linter-erb@1.1.4
    ├── linter-rubocop@2.4.2
    ├── linter-ruby@1.3.1
    ├── linter-spell@0.15.0
    ├── linter-ui-default@1.7.1
    ├── monokai@0.24.0
    ├── multi-cursor@2.1.5
    ├── native-ui@0.27.0
    ├── pigments@0.40.2
    ├── prettier-atom@0.57.2
    ├── react@0.18.0
    ├── rubocop-auto-correct@1.5.1
    ├── ruby-block@0.3.6
    ├── seti-icons@1.5.4
    ├── seti-syntax@1.2.0
    ├── seti-ui@1.11.0
    ├── tailwind-docs@1.0.0
    └── vim-mode-plus@1.36.1 (disabled)
  1. config.cson
    "*":
      "atom-beautify":
        erb: {}
      core:
        disabledPackages: [
          "language-gfm"
          "spell-check"
          "vim-mode-plus"
        ]
        telemetryConsent: "no"
        themes: [
          "one-dark-ui"
          "solarized-light-syntax"
        ]
      editor:
        fontSize: 13
        invisibles: {}
        showIndentGuide: true
        zoomFontWhenCtrlScrolling: true
      "exception-reporting":
        userId: "768d361e-dc9f-4024-86f5-e14055f97d89"
      fonts:
        fontFamily: "Roboto Mono"
      "fuzzy-finder":
        scoringSystem: "fast"
        useRipGrep: true
      "git-diff":
        showIconsInEditorGutter: true
      linter:
        disabledProviders: [
          "ERB"
        ]
      "linter-ui-default":
        panelHeight: 297
      minimap:
        plugins:
          "highlight-selected": true
          "highlight-selectedDecorationsZIndex": 0
      "prettier-atom":
        formatOnSaveOptions:
          enabled: true
          showInStatusBar: true
        useEslint: true
      "ruby-block":
        highlightLineNumber: true
      "seti-icons":
        noColor: true
      "seti-syntax":
        themeColor: "Steel"
      "seti-ui":
        compactView: true
        hideProjectTab: true
      "tree-view": {}
      welcome:
        showOnStartup: false
  1. init.coffee
# Your init script
#
# Atom will evaluate this file each time a new window is opened. It is run
# after packages are loaded/activated and after the previous editor state
# has been restored.
#
# An example hack to log to the console when each text editor is saved.
#
# atom.workspace.observeTextEditors (editor) ->
#   editor.onDidSave ->
#     console.log "Saved! #{editor.getPath()}"
  1. I had a system crash and laptop restarted. The page that got lost was the page that I was currently focused on. The other tabs that were open are fine and recovered with no issues.

Pretty sad day for me, hope this gets fixed. Really love Atom compared to the other editors currently in the market! Funny thing was, I was just about to add and commit my new files when this occurred :confused: Let me know if I can provided any other logs!

Clearly you did not follow earlier ideas in this thread … such as local-history package. However I see that you have withdrawn your post I refer to.

Was that local-history package useful for you? I lost all of my code today and I don’t have enough time to rewrite that.

It does not work after the event. It is insurance against loss, but I would still try other routine backup methods such as a cron script to backup your important files.

This is still happening. Crashed when I clicked save.

on unexpected power fluctuation pc shutdown/on/down/on and the working file ended up blank, all other open tabs were fine

windows 10 version1909 build 18363.900
atom version 1.48.0

package list

    Built-in Atom Packages (93)
├── atom-dark-syntax@0.29.1
├── atom-dark-ui@0.53.3
├── atom-light-syntax@0.29.1
├── atom-light-ui@0.46.3
├── base16-tomorrow-dark-theme@1.6.0
├── base16-tomorrow-light-theme@1.6.0
├── one-dark-ui@1.12.5
├── one-light-ui@1.12.5
├── one-dark-syntax@1.8.4
├── one-light-syntax@1.8.4
├── solarized-dark-syntax@1.3.0
├── solarized-light-syntax@1.3.0
├── about@1.9.1
├── archive-view@0.65.2
├── autocomplete-atom-api@0.10.7
├── autocomplete-css@0.17.5
├── autocomplete-html@0.8.8
├── autocomplete-plus@2.42.3
├── autocomplete-snippets@1.12.1
├── autoflow@0.29.4
├── autosave@0.24.6
├── background-tips@0.28.0
├── bookmarks@0.46.0
├── bracket-matcher@0.91.2
├── command-palette@0.43.5
├── dalek@0.2.2
├── deprecation-cop@0.56.9
├── dev-live-reload@0.48.1
├── encoding-selector@0.23.9
├── exception-reporting@0.43.1
├── find-and-replace@0.219.3
├── fuzzy-finder@1.14.2
├── github@0.34.2
├── git-diff@1.3.9
├── go-to-line@0.33.0
├── grammar-selector@0.50.1
├── image-view@0.64.0
├── incompatible-packages@0.27.3
├── keybinding-resolver@0.39.0
├── line-ending-selector@0.7.7
├── link@0.31.6
├── markdown-preview@0.160.2
├── metrics@1.8.1
├── notifications@0.71.0
├── open-on-github@1.3.2
├── package-generator@1.3.0
├── settings-view@0.261.4
├── snippets@1.5.1
├── spell-check@0.76.1
├── status-bar@1.8.17
├── styleguide@0.49.12
├── symbols-view@0.118.4
├── tabs@0.110.0
├── timecop@0.36.2
├── tree-view@0.228.0
├── update-package-dependencies@0.13.1
├── welcome@0.36.9
├── whitespace@0.37.7
├── wrap-guide@0.41.0
├── language-c@0.60.19
├── language-clojure@0.22.8
├── language-coffee-script@0.50.0
├── language-csharp@1.1.0
├── language-css@0.44.4
├── language-gfm@0.90.7
├── language-git@0.19.1
├── language-go@0.47.2
├── language-html@0.53.1
├── language-hyperlink@0.17.1
├── language-java@0.31.5
├── language-javascript@0.134.1
├── language-json@1.0.5
├── language-less@0.34.3
├── language-make@0.23.0
├── language-mustache@0.14.5
├── language-objective-c@0.16.0
├── language-perl@0.38.1
├── language-php@0.44.4
├── language-property-list@0.9.1
├── language-python@0.53.4
├── language-ruby@0.72.23
├── language-ruby-on-rails@0.25.3
├── language-rust-bundled@0.1.0
├── language-sass@0.62.1
├── language-shellscript@0.28.2
├── language-source@0.9.0
├── language-sql@0.25.10
├── language-text@0.7.4
├── language-todo@0.29.4
├── language-toml@0.20.0
├── language-typescript@0.6.2
├── language-xml@0.35.3
└── language-yaml@0.32.0

Community Packages (12) C:\Users\mdaas\.atom\packages
├── autoclose-html@0.23.0
├── busy-signal@2.0.1
├── color-picker@2.3.0
├── django-templates@0.5.0
├── docblockr@0.13.7
├── highlight-selected@0.17.0
├── intentions@1.1.5
├── jsonlint@1.1.4
├── linter@2.3.1
├── linter-ui-default@1.8.1
├── minimap@4.29.9
└── pigments@0.40.2

config.cson

    "*":
  core:
    telemetryConsent: "no"
  editor:
    fontSize: 18
  "exception-reporting":
    userId: "6333dbdd-0c2c-47a2-9efb-b6cd754a0df1"
  "linter-ui-default":
    panelHeight: 249
    showPanel: true
  welcome:
    showOnStartup: false

init.coffee

# Your init script
#
# Atom will evaluate this file each time a new window is opened. It is run
# after packages are loaded/activated and after the previous editor state
# has been restored.
#
# An example hack to log to the console when each text editor is saved.
#
# atom.workspace.observeTextEditors (editor) ->
#   editor.onDidSave ->
#     console.log "Saved! #{editor.getPath()}"

i added these files because that’s what the most recent person did…

Hi, this happened to me today, entire day’s work has gone, this file was open and I was working in it when the power outage occurred and when reopened the file was blank, rest of the files in the open tabs are fine. really frustrated.

Atom Version: 1.50.0 x64

Same here. Got a blue screen of death, then the file I was working on turned into mush, a bunch of nonsense that Atom interpreted as some kind of whitespace.

Same happened to me. Several days of work. I was warned by colleagues “Atom is a mess” but I just wanted to try Julia with a minimal setup overhead so I went for JuliaPro with Atom/Juno. I’ve used VS, VScode, Rstudio and minimalistic tools such as Notepad++ and it never happened. On top of that Atom cpu burden was not bearable. Enough, I’m switching to VScode.
Sorry for not being very constructive but to me easily restoring files after a computer crash is a minimum for any editing software.

Same here :frowning: I took a lot of time modifying Atom and today I lost everything. I don’t even have a recovery folder. I guess from now on I’ll be saving my settings, but still I thing Atom should have a better solution.

This is not enough to make me go back to VScode :joy: I love all you can do with Atom, is just that is incredible annoying to create the perfect development environment and then losing all your work.

@nerdalot can you consistently reproduce your issue? I was working on a simple plugin just for that case, using swapfiles as an extra layer of security, but I can’t reproduce my issue to test it.

When it happened to me, I got a blue screen JUST as I was saving the file, but it’s impossible to reproduce. I tried many alternatives but Atom just seems to work every time ^^;

I like the swapfiles alternative because even if something goes horribly wrong as you save, you always have a plain-text copy that you can recover. Worst case scenario you lose a few seconds of work.

Can’t believe this just happened to me too… in 2020. After a unexpected system crash, a source file I have been working on has gone blank. The rest of the files on the project folder are ok. It only affected the file that was open in the editor at the the time. It’s a bit painful because I was working locally at the the time and didn’t commit my changes yet to git. I’m using version 1.51.0