banacorn / language-agda

Agda language support for the Atom editor
https://atom.io/packages/language-agda
MIT License
13 stars 5 forks source link

Failed to load a language-agda package grammar #14

Closed fabrizioschiavi closed 5 years ago

fabrizioschiavi commented 6 years ago

[Enter steps to reproduce:]

  1. ...
  2. ...

Atom: 1.28.2 x64 Electron: 2.0.5 OS: Mac OS X 10.13.6 Thrown From: language-agda package 1.0.3

Stack Trace

Failed to load a language-agda package grammar

At The module '/Users/fabrizio/.atom/packages/language-agda/node_modules/tree-sitter-agda/build/Release/tree_sitter_agda_binding.node'
was compiled against a different Node.js version using
NODE_MODULE_VERSION 54. This version of Node.js requires
NODE_MODULE_VERSION 57. Please try re-compiling or re-installing
the module (for instance, using `npm rebuild` or `npm install`). in /Users/fabrizio/.atom/packages/language-agda/grammars/tree-sitter-agda.cson

Error: The module '/Users/fabrizio/.atom/packages/language-agda/node_modules/tree-sitter-agda/build/Release/tree_sitter_agda_binding.node'
was compiled against a different Node.js version using
NODE_MODULE_VERSION 54. This version of Node.js requires
NODE_MODULE_VERSION 57. Please try re-compiling or re-installing
the module (for instance, using `npm rebuild` or `npm install`).
    at process.module.(anonymous function) [as dlopen] (ELECTRON_ASAR.js:172:20)
    at Object.Module._extensions..node (module.js:671:18)
    at Object.module.(anonymous function) [as .node] (ELECTRON_ASAR.js:172:20)
    at Module.load (module.js:561:32)
    at tryModuleLoad (module.js:504:12)
    at Function.Module._load (module.js:496:3)
    at Module.require (/app.asar/static/index.js:47:45)
    at require (/Applications/Atom.app/Contents/Resources/app/src/native-compile-cache.js:66:33)
    at /packages/language-agda/node_modules/tree-sitter-agda/index.js:2:20)
    at /packages/language-agda/node_modules/tree-sitter-agda/index.js:11:3)
    at Module.get_Module._compile (/Applications/Atom.app/Contents/Resources/app/src/native-compile-cache.js:106:36)
    at Object.value [as .js] (/Applications/Atom.app/Contents/Resources/app/src/compile-cache.js:240:29)
    at Module.load (module.js:561:32)
    at tryModuleLoad (module.js:504:12)
    at Function.Module._load (module.js:496:3)
    at Module.require (/app.asar/static/index.js:47:45)
    at require (internal/module.js:11:18)
    at customRequire (/Applications/Atom.app/Contents/Resources/app/static/<embedded>:96:26)
    at new TreeSitterGrammar (/Applications/Atom.app/Contents/Resources/app/src/tree-sitter-grammar.js:49:33)
    at GrammarRegistry.createGrammar (/Applications/Atom.app/Contents/Resources/app/src/grammar-registry.js:494:20)
    at CSON.readFile (/Applications/Atom.app/Contents/Resources/app/src/grammar-registry.js:476:35)
    at /Applications/Atom.app/Contents/Resources/app/node_modules/season/lib/cson.js:223:65
    at FSReqWrap.readFileAfterClose [as oncomplete] (fs.js:511:3)
  at /packages/language-agda/grammars/tree-sitter-agda.cson:1:1

Commands

Non-Core Packages

agda-mode 0.7.15 
atom-fuzzy-grep 0.17.2 
atom-svg-icon-snippets 0.3.3 
diagrams 0.28.4 
graphviz-preview-plus 1.5.5 
language-agda 1.0.3 
language-dot 1.7.0 
language-markdown 0.26.0 
language-svg 0.9.2 
markdown-helpers 0.3.0 
markdown-pdf 2.2.0 
markdown-scroll-sync 2.1.2 
markdown-themeable-pdf 1.2.1 
opentype-feature-bundle 0.2.4 
regex-railroad-diagram 0.19.4 
simple-drag-drop-text 0.4.0 
svg-clear 0.1.4 
svg-preview 0.12.1 
svgo 3.1.0 
banacorn commented 6 years ago

Thanks for reporting this! I'll see what I can do and a new patch should be coming in a few days.

In the meantime, I will remove language-agda as a hard dependency of agda-mode (assuming you have the need).

banacorn commented 6 years ago

Please upgrade to the latest version (v1.0.4) and see if everything is fine (or in flames?)

banacorn commented 5 years ago

I'm closing this because the problem should've been long gone

banacorn commented 5 years ago

UPDATE, for newcomers: If you still get this error message after you upgraded your Atom or language-agda (or both), uninstall and then reinstall language-agda and this error message should go away.