Skip to content
This repository has been archived by the owner on Dec 15, 2022. It is now read-only.

Launching atom -d hangs, apm test crashes #543

Closed
4 of 6 tasks
florianb opened this issue Apr 12, 2016 · 4 comments
Closed
4 of 6 tasks

Launching atom -d hangs, apm test crashes #543

florianb opened this issue Apr 12, 2016 · 4 comments

Comments

@florianb
Copy link

Prerequisites

For more information on how to write a good bug report or enhancement request, see the CONTRIBUTING guide.

Description

If i launch atom -d from command-line, Atom gets started (task-bar-item appears, menu changes name and items) but no window is created.

If i try to invoke any apm test i get this exception, which hangs at the end, creating full CPU usage:

2016-04-12 12:51:45.477 Atom[73566:7805158] Cannot find module 'underscore-plus'
2016-04-12 12:51:45.509 Atom[73566:7805158] Error: Cannot find module 'underscore-plus'
    at Function.Module._resolveFilename (module.js:336:15)
    at Function.Module._load (module.js:286:25)
    at Module.require (module.js:365:17)
    at require (module.js:384:17)
    at Object.<anonymous> (/Users/florianbreisch/github/atom/src/browser/atom-window.coffee:7:5)
    at Object.<anonymous> (/Users/florianbreisch/github/atom/src/browser/atom-window.coffee:1:1)
    at Module._compile (module.js:434:26)
    at Object.defineProperty.value [as .coffee] (/Applications/Atom.app/Contents/Resources/app.asar/src/compile-cache.js:208:21)
    at Module.load (module.js:355:32)
    at Function.Module._load (module.js:310:12)
    at Module.require (module.js:365:17)
    at require (module.js:384:17)
    at Object.<anonymous> (/Users/florianbreisch/github/atom/src/browser/atom-application.coffee:1:14)
    at Object.<anonymous> (/Users/florianbreisch/github/atom/src/browser/atom-application.coffee:1:1)
    at Module._compile (module.js:434:26)
    at Object.defineProperty.value [as .coffee] (/Applications/Atom.app/Contents/Resources/app.asar/src/compile-cache.js:208:21)
    at Module.load (module.js:355:32)
    at Function.Module._load (module.js:310:12)
    at Module.require (module.js:365:17)
    at require (module.js:384:17)
    at EventEmitter.<anonymous> (/Applications/Atom.app/Contents/Resources/app.asar/src/browser/main.js:54:25)
    at emitOne (events.js:82:20)
    at EventEmitter.emit (events.js:169:7)

Launching Atom in normal- or safe-mode works fine - there are no unexpected error messages or warnings.

In order to fix that i unlinked all packages, completely rebuild any caches, deleted and reinstalled dedicated node_modules/. The dev-directory (~/.atom/dev/packages) is empty, i disabled all packages.

Steps to Reproduce

I really don't know how this could happen and what i may have done to make this happen. I even don't know how to fix it.

Versions

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.6.4

ProductName:    Mac OS X
ProductVersion: 10.11.4
BuildVersion:   15E65

P.s.: i guess i'm right here and had this issue wrongly filed at atom/atom#11433 too.

@winstliu
Copy link
Contributor

Just to be sure I'm understanding this line...

In order to fix that i unlinked all packages, completely rebuild any caches, deleted and reinstalled dedicated node_modules/. The dev-directory (~/.atom/dev/packages) is empty, i disabled all packages.

did you run script/build before attempting to start Atom using atom -d or apm test?

(Also, this does actually belong on atom/atom, but I'll leave it here for now)

@florianb
Copy link
Author

sorry, i thought it belongs to apm since apm test doesn't run.

No i didn't try to build Atom myself, i just thought i could have accidentially mixed up any module caches. That's why i invoked apm rebuild-module-cache and deleted the node-modules of the packages i was developing.

@winstliu
Copy link
Contributor

atom -d invokes dev mode, which runs your local copy of Atom (~/github/Atom) and not the installed version. In order for that to run though you'll need to have built it first. apm test calls atom --dev --test spec internally (or something like that).

Alternatively if you don't want to go through that trouble setting ATOM_DEV_RESOURCE_PATH to somewhere else should do the trick.

@florianb
Copy link
Author

Oh man - i am sorry, i recently cloned Atom to check some tests and until then everything was fine. I was completely unaware that apm would recognize that new clone. I'm going to try to get it running. Thanks for that hint - i guess i would have never found this out by myself! ❤️

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

2 participants