[Atom] How to fix 'The editor has crashed' error #AtomEditor

Tadashi Shigeoka ·  Thu, November 5, 2015

When I got to work and tried to start Atom editor as usual, it wouldn’t start up due to a The editor has crashed error.

I was able to successfully resolve the error, so I’ll share the solution.

How to fix 'The editor has crashed' error

The editor has crashed | Atom.io

The solution to make Atom start up again was:

  1. Check installed packages with apm list
  2. Uninstall packages with apm uninstall --hard packageName
  3. Check if Atom can start without errors

It seemed like the only way was to repeat this procedure for each package.

If Atom starts normally after uninstalling a package, that package should be the cause of the error.

Investigation process

I’ll record what I investigated before arriving at the solution of “uninstall packages one by one and try starting Atom”.

First, I started Atom with options to check the logs.

$ atom -d -f .
2015-11-05 10:20:31.096 Atom[12864:6941378] App load time: 276ms
[12864:1105/102031:INFO:CONSOLE(387)] "Could not load [email protected] because it uses deprecated APIs that have been removed.", source: /Applications/Atom.app/Contents/Resources/app.asar/src/package-manager.js (387)

atom-beautifier seemed problematic, so I uninstalled it.

$ apm uninstall atom-beautifier
Uninstalling atom-beautifier ✓

Since the logs stopped appearing, I tried running with the —test option next.

$ atom --test
[13257:1105/103003:INFO:CONSOLE(27)] "Error: Cannot find module '../lib/atom-jshint-view'
  at Module._resolveFilename (module.js:334:15)
  at Function.Module._resolveFilename (/Applications/Atom.app/Contents/Resources/app.asar/src/module-cache.js:383:52)
  at Function.Module._load (module.js:284:25)
  at Module.require (module.js:363:17)
  at require (module.js:382:17)
  at Object. (/Users/username/.atom/packages/atom-jshint/spec/atom-jshint-view-spec.coffee:1:18)
  at Object. (/Users/username/.atom/packages/atom-jshint/spec/atom-jshint-view-spec.coffee:1:1)
  at Module._compile (module.js:428:26)
  at Object.defineProperty.value [as .coffee] (/Applications/Atom.app/Contents/Resources/app.asar/src/compile-cache.js:169:21)
  at Module.load (/Applications/Atom.app/Contents/Resources/app.asar/node_modules/coffee-script/lib/coffee-script/register.js:45:36)
  at Function.Module._load (module.js:308:12)
  at Module.require (module.js:363:17)
  at require (module.js:382:17)
  at requireSpecs (/Applications/Atom.app/Contents/Resources/app.asar/spec/spec-suite.js:21:7)
  at runAllSpecs (/Applications/Atom.app/Contents/Resources/app.asar/spec/spec-suite.js:78:7)
  at Object. (/Applications/Atom.app/Contents/Resources/app.asar/spec/spec-suite.js:87:5)
  at Object. (/Applications/Atom.app/Contents/Resources/app.asar/spec/spec-suite.js:90:4)
  at Module._compile (module.js:428:26)
  at Object.defineProperty.value [as .js] (/Applications/Atom.app/Contents/Resources/app.asar/src/compile-cache.js:169:21)
  at Module.load (/Applications/Atom.app/Contents/Resources/app.asar/node_modules/coffee-script/lib/coffee-script/register.js:45:36)
  at Function.Module._load (module.js:308:12)
  at Module.require (module.js:363:17)
  at require (module.js:382:17)
  at module.exports.runSpecSuite (/Applications/Atom.app/Contents/Resources/app.asar/spec/jasmine-helper.js:60:5)
  at Object. (/Applications/Atom.app/Contents/Resources/app.asar/spec/spec-bootstrap.js:23:5)
  at Object. (/Applications/Atom.app/Contents/Resources/app.asar/spec/spec-bootstrap.js:34:4)
  at Module._compile (module.js:428:26)
  at Object.defineProperty.value [as .js] (/Applications/Atom.app/Contents/Resources/app.asar/src/compile-cache.js:169:21)
  at Module.load (module.js:353:32)
  at Function.Module._load (module.js:308:12)
  at Module.require (module.js:363:17)
  at require (module.js:382:17)
  at setupWindow (file:///Applications/Atom.app/Contents/Resources/app.asar/static/index.js:79:25)
  at window.onload (file:///Applications/Atom.app/Contents/Resources/app.asar/static/index.js:35:9)
", source: /Applications/Atom.app/Contents/Resources/app.asar/spec/spec-bootstrap.js (27)

The atom-jshint package seemed to be causing the error, so I uninstalled this too.

$ apm uninstall atom-jshint
Uninstalling atom-jshint ✓

When I ran the test again, no logs were output, but the “The editor has crashed” error remained unresolved.

$ atom --test

I wanted a clean solution flow of checking error logs to identify the problem, but with no more clues, I eventually arrived at the procedure mentioned at the beginning of “uninstall suspicious packages one by one”.

If you know a better solution method, please let me know.

Reference information

That’s all from the Gemba.