emmet-atom icon indicating copy to clipboard operation
emmet-atom copied to clipboard

Failed to load the emmet package

Open neticcul2se opened this issue 10 years ago • 15 comments

[Enter steps to reproduce below:]

  1. ...
  2. ...

Atom Version: 1.0.0 System: Mac OS X 10.10.3 Thrown From: emmet package, v2.3.10

Stack Trace

Failed to load the emmet package

At Cannot find module 'emmet'

Error: Cannot find module 'emmet'
  at Module._resolveFilename (module.js:328:15)
  at Function.Module._resolveFilename (/Users/Apple/Desktop/Atom.app/Contents/Resources/app.asar/src/module-cache.js:383:52)
  at Function.Module._load (module.js:270:25)
  at Module.require (module.js:357:17)
  at require (module.js:376:17)
  at Object.<anonymous> (/Users/Apple/.atom/packages/emmet-atom/lib/emmet.coffee:5:9)
  at Object.<anonymous> (/Users/Apple/.atom/packages/emmet-atom/lib/emmet.coffee:1:1)
  at Module._compile (module.js:452:26)
  at Object.requireCoffeeScript (/Users/Apple/Desktop/Atom.app/Contents/Resources/app.asar/node_modules/coffee-cash/lib/coffee-cash.js:85:19)
  at Module.load (module.js:347:32)
  at Function.Module._load (module.js:302:12)
  at Module.require (module.js:357:17)
  at require (module.js:376:17)
  at Package.module.exports.Package.requireMainModule (/Users/Apple/Desktop/Atom.app/Contents/Resources/app.asar/src/package.js:709:34)
  at /Users/Apple/Desktop/Atom.app/Contents/Resources/app.asar/src/package.js:188:28
  at Package.module.exports.Package.measure (/Users/Apple/Desktop/Atom.app/Contents/Resources/app.asar/src/package.js:165:15)
  at Package.module.exports.Package.load (/Users/Apple/Desktop/Atom.app/Contents/Resources/app.asar/src/package.js:179:12)
  at PackageManager.module.exports.PackageManager.loadPackage (/Users/Apple/Desktop/Atom.app/Contents/Resources/app.asar/src/package-manager.js:372:14)
  at PackageManager.module.exports.PackageManager.loadPackages (/Users/Apple/Desktop/Atom.app/Contents/Resources/app.asar/src/package-manager.js:336:14)
  at Atom.module.exports.Atom.startEditorWindow (/Users/Apple/Desktop/Atom.app/Contents/Resources/app.asar/src/atom.js:638:21)
  at Object.<anonymous> (/Users/Apple/Desktop/Atom.app/Contents/Resources/app.asar/src/window-bootstrap.js:12:8)
  at Object.<anonymous> (/Users/Apple/Desktop/Atom.app/Contents/Resources/app.asar/src/window-bootstrap.js:23:4)
  at Module._compile (module.js:452:26)
  at Object.loadFile [as .js] (/Users/Apple/Desktop/Atom.app/Contents/Resources/app.asar/src/babel.js:162:21)
  at Module.load (module.js:347:32)
  at Function.Module._load (module.js:302:12)
  at Module.require (module.js:357:17)
  at require (module.js:376:17)
  at setupWindow (file:///Users/Apple/Desktop/Atom.app/Contents/Resources/app.asar/static/index.js:96:23)
  at window.onload (file:///Users/Apple/Desktop/Atom.app/Contents/Resources/app.asar/static/index.js:36:7)

Commands

Config

{
  "core": {
    "themes": [
      "one-dark-ui",
      "atom-dark-syntax"
    ]
  }
}

Installed Packages

# User
atom-html-preview, v0.1.8

# Dev
No dev packages


Want to back this issue? Post a bounty on it! We accept bounties via Bountysource.

neticcul2se avatar Jun 26 '15 06:06 neticcul2se

It looks like you didn’t installed Emmet properly. Try to re-install it

sergeche avatar Jun 26 '15 10:06 sergeche

I have the same problem now. Re-install doesnt help.

MazheM avatar Sep 19 '15 21:09 MazheM

Hi! I have the same problem. I have started to learn coding. Our teacher uses Atom. I don't know what to do. Help me please.

[Enter steps to reproduce below:]

  1. ...
  2. ...

Atom Version: 1.0.19 System: Unknown Windows Version Thrown From: emmet package, v2.3.13

Stack Trace

Failed to load the emmet package

At Cannot find module 'emmet'

Error: Cannot find module 'emmet'
    at Module._resolveFilename (module.js:334:15)
    at Function.Module._resolveFilename (C:\Users\Алина\AppData\Local\atom\app-1.0.19\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.<anonymous> (C:\Users\Алина\.atom\packages\emmet\lib\emmet.coffee:5:9)
    at Object.<anonymous> (C:\Users\Алина\.atom\packages\emmet\lib\emmet.coffee:1:1)
    at Module._compile (module.js:428:26)
    at Object.defineProperty.value [as .coffee] (C:\Users\Алина\AppData\Local\atom\app-1.0.19\resources\app.asar\src\compile-cache.js:169:21)
    at Module.load (module.js:353:32)

Commands

Config

{
  "core": {}
}

Installed Packages

# User
emmet, v2.3.13

# Dev
No dev packages

Sej7 avatar Oct 01 '15 16:10 Sej7

It means Emmet is not properly installed, e.g. there’s no core emmet package that should be installed by NPM.

Try the following:

  1. In command prompt/console go to Emmet package folder (in your case it’s C:\Users\Алина\.atom\packages\emmet)
  2. Run npm install. You may need to install Node.js/NPM before doing so.
  3. Restart Atom

sergeche avatar Oct 01 '15 16:10 sergeche

Thank you. I did all that you told but without changes. Result is below. 2015-10-01_213536 What do you recomend?

Sej7 avatar Oct 01 '15 18:10 Sej7

Do you have C:\Users\Алина\.atom\packages\emmet\node_modules\emmet folder with some JS files in it?

sergeche avatar Oct 01 '15 20:10 sergeche

Yes, I have. There are some folders including many files with extension ".js". I also tried to use a command prompt in admin mode. Result is the same.

Sej7 avatar Oct 02 '15 06:10 Sej7

I tried a complete reinstall of the atom, but it did not help, getting this error when installing. If it is necessary, that the contents of the folder node_modules/emmet: screenshot

MazheM avatar Oct 10 '15 20:10 MazheM

It seems this is Atom problem: https://github.com/atom/atom/issues/8891 https://discuss.atom.io/t/atom-throwing-several-failed-to-load-the-xyz-package-errors/20969

Possible problem: user profile folder contains non-latin characters in name. Possible solution: change user profile folder name.(I tried this but after changing some rights on the folder, Windows has ceased to work correctly with the profile folder and I reinstalled Windows completely. Now Atom and Emmet are working properly.). Or create a new profile, where there is no non-Latin characters in the name.

MazheM avatar Oct 14 '15 21:10 MazheM

Thanks for the heads-up, @MazheM :+1:

sergeche avatar Oct 14 '15 21:10 sergeche

cd .atom/packages $ git clone https://github.com/emmetio/emmet-atom (windows) $ cd emmet-atom $ npm install and ok~

raylhx avatar Apr 06 '17 12:04 raylhx

This problem is because you don't have node.js and npm. You can install node.js and npm,then try it again.

Fallen-Angle-Lucifer avatar May 01 '17 11:05 Fallen-Angle-Lucifer

I am using a translator. I got the same error and what I did was to install the atom-nodejs-snipptes then uninstall the emmet delete in the package the emmet I installed by console and then I could install the emmet quietly

bradvr avatar Nov 01 '17 16:11 bradvr

fix this by typing: "npm install" on console (~ / .atom / packages / emmet-atom (from this directory)) at installing was mistake, and console recommended to use another command

ochedenis avatar Apr 22 '18 21:04 ochedenis

Clearing the compile cache resolved the issue for me on Mac.

https://discuss.atom.io/t/atom-throwing-several-failed-to-load-the-xyz-package-errors/20969/3

Try this:

Completely close all instances of Atom
Delete the directory ~/.atom/compile-cache
Start Atom again

happyboredom avatar Dec 03 '19 18:12 happyboredom