Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Parse errors #16

Closed
drandreaskrueger opened this issue Nov 8, 2017 · 11 comments
Closed

Parse errors #16

drandreaskrueger opened this issue Nov 8, 2017 · 11 comments

Comments

@drandreaskrueger
Copy link

drandreaskrueger commented Nov 8, 2017

Fantastic, I have been looking for s.th. like this for a long time; really happy solgraph was mentioned in Hudson Jameson's DevCon3 talk last week.

Small issue - I get parser errors for some contracts.

How to replicate:

git clone https://github.com/raiden-network/raiden
cd raiden/raiden/smart_contracts/
find . -type f -name "*.sol" -printf "solgraph %p > %p.dot\n" | bash
find . -type f -name "*.dot" -printf "dot -Tpng %p > %p.png\n" | bash

8 out of the 10 contracts are fine, but for two of them (ChannelManagerContract.sol & Token.sol) I get these parser errors:

Parse error
{ SyntaxError: Expected "contract", "import", "library", "pragma", comment, end of input, end of line, or whitespace but "i" found. Line: 3, Column: 1
    at peg$buildStructuredError (/usr/lib/node_modules/solgraph/node_modules/solidity-parser/build/parser.js:1272:12)
    at Object.peg$parse [as parse] (/usr/lib/node_modules/solgraph/node_modules/solidity-parser/build/parser.js:13858:11)
    at Object.parse (/usr/lib/node_modules/solgraph/node_modules/solidity-parser/index.js:34:23)
    at exports.default (/usr/lib/node_modules/solgraph/dist/index.js:70:21)
    at /usr/lib/node_modules/solgraph/dist/bin.js:37:35
  message: 'Expected "contract", "import", "library", "pragma", comment, end of input, end of line, or whitespace but "i" found. Line: 3, Column: 1',
  expected: 
   [ { type: 'other', description: 'whitespace' },
     { type: 'other', description: 'end of line' },
     { type: 'other', description: 'comment' },
     { type: 'literal', text: 'pragma', ignoreCase: false },
     { type: 'literal', text: 'import', ignoreCase: false },
     { type: 'literal', text: 'import', ignoreCase: false },
     { type: 'literal', text: 'import', ignoreCase: false },
     { type: 'literal', text: 'contract', ignoreCase: false },
     { type: 'literal', text: 'library', ignoreCase: false },
     { type: 'other', description: 'whitespace' },
     { type: 'other', description: 'end of line' },
     { type: 'other', description: 'comment' },
     { type: 'end' } ],
  found: 'i',
  location: 
   { start: { offset: 26, line: 3, column: 1 },
     end: { offset: 27, line: 3, column: 2 } },
  name: 'SyntaxError' }

Parse error
{ SyntaxError: Expected comment, end of line, identifier, or whitespace but "," found. Line: 104, Column: 28
    at peg$buildStructuredError (/usr/lib/node_modules/solgraph/node_modules/solidity-parser/build/parser.js:1272:12)
    at Object.peg$parse [as parse] (/usr/lib/node_modules/solgraph/node_modules/solidity-parser/build/parser.js:13858:11)
    at Object.parse (/usr/lib/node_modules/solgraph/node_modules/solidity-parser/index.js:34:23)
    at exports.default (/usr/lib/node_modules/solgraph/dist/index.js:70:21)
    at /usr/lib/node_modules/solgraph/dist/bin.js:37:35
  message: 'Expected comment, end of line, identifier, or whitespace but "," found. Line: 104, Column: 28',
  expected: 
   [ { type: 'other', description: 'whitespace' },
     { type: 'other', description: 'end of line' },
     { type: 'other', description: 'comment' },
     { type: 'other', description: 'identifier' } ],
  found: ',',
  location: 
   { start: { offset: 3407, line: 104, column: 28 },
     end: { offset: 3408, line: 104, column: 29 } },
  name: 'SyntaxError' }

These are all the images of those contracts which succeed getting parsed: raiden-solidity-solgraph-for-printing.pdf Really great, thanks a lot!

@raineorshine
Copy link
Owner

Thank you! This should be remedied as soon as we upgrade to the latest version of solidity.

@raineorshine raineorshine changed the title Parse error Parse errors Jun 24, 2018
@raineorshine
Copy link
Owner

Fixed in v0.3.0.

Only omission is that constructor and fallback are being labeled null. Tracked in #28.

@drandreaskrueger
Copy link
Author

sudo npm install -g solgraph

npm WARN deprecated @babel/preset-es2015@7.0.0-beta.53: 👋 We've deprecated any official yearly presets in 6.x in favor or babel-preset-env. For 7.x it would be @babel/preset-env.
/usr/local/bin/solgraph -> /usr/local/lib/node_modules/solgraph/solgraph.js

> solgraph@0.3.2 postinstall /usr/local/lib/node_modules/solgraph
> npm run build

npm ERR! path /root/.npm/_logs
npm ERR! code EACCES
npm ERR! errno -13
npm ERR! syscall scandir
npm ERR! Error: EACCES: permission denied, scandir '/root/.npm/_logs'
npm ERR!  { Error: EACCES: permission denied, scandir '/root/.npm/_logs'
npm ERR!   stack: 'Error: EACCES: permission denied, scandir \'/root/.npm/_logs\'',
npm ERR!   errno: -13,
npm ERR!   code: 'EACCES',
npm ERR!   syscall: 'scandir',
npm ERR!   path: '/root/.npm/_logs' }
npm ERR! 
npm ERR! The operation was rejected by your operating system.
npm ERR! It is likely you do not have the permissions to access this file as the current user
npm ERR! 
npm ERR! If you believe this might be a permissions issue, please double-check the
npm ERR! permissions of the file and its containing directories, or try running
npm ERR! the command again as root/Administrator (though this is not recommended).
glob error { Error: EACCES: permission denied, scandir '/root/.npm/_logs'
  stack: 'Error: EACCES: permission denied, scandir \'/root/.npm/_logs\'',
  errno: -13,
  code: 'EACCES',
  syscall: 'scandir',
  path: '/root/.npm/_logs' }

> solgraph@0.3.2 build /usr/local/lib/node_modules/solgraph
> babel -d dist src

{ Error: Cannot find module '@babel/preset-es2015' from '/usr/local/lib/node_modules/solgraph'
    at Function.module.exports [as sync] (/usr/local/lib/node_modules/solgraph/node_modules/resolve/lib/sync.js:43:15)
    at resolveStandardizedName (/usr/local/lib/node_modules/solgraph/node_modules/@babel/core/lib/config/files/plugins.js:101:31)
    at resolvePreset (/usr/local/lib/node_modules/solgraph/node_modules/@babel/core/lib/config/files/plugins.js:58:10)
    at loadPreset (/usr/local/lib/node_modules/solgraph/node_modules/@babel/core/lib/config/files/plugins.js:77:20)
    at createDescriptor (/usr/local/lib/node_modules/solgraph/node_modules/@babel/core/lib/config/config-descriptors.js:114:9)
    at items.map (/usr/local/lib/node_modules/solgraph/node_modules/@babel/core/lib/config/config-descriptors.js:69:50)
    at Array.map (<anonymous>)
    at createDescriptors (/usr/local/lib/node_modules/solgraph/node_modules/@babel/core/lib/config/config-descriptors.js:69:29)
    at createPresetDescriptors (/usr/local/lib/node_modules/solgraph/node_modules/@babel/core/lib/config/config-descriptors.js:61:10)
    at presets (/usr/local/lib/node_modules/solgraph/node_modules/@babel/core/lib/config/config-descriptors.js:43:19) code: 'MODULE_NOT_FOUND' }
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! solgraph@0.3.2 build: `babel -d dist src`
npm ERR! Exit status 1
npm ERR! 
npm ERR! Failed at the solgraph@0.3.2 build script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.4 (node_modules/solgraph/node_modules/fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.4: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})

npm ERR! code ELIFECYCLE
npm ERR! errno 243
npm ERR! solgraph@0.3.2 postinstall: `npm run build`
npm ERR! Exit status 243
npm ERR! 
npm ERR! Failed at the solgraph@0.3.2 postinstall script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     /root/.npm/_logs/2018-08-06T12_58_33_649Z-debug.log

npm install solgraph

npm WARN deprecated @babel/preset-es2015@7.0.0-beta.53: 👋 We've deprecated any official yearly presets in 6.x in favor or babel-preset-env. For 7.x it would be @babel/preset-env.

> solgraph@0.3.2 postinstall /home/akrueger/node_modules/solgraph
> npm run build


> solgraph@0.3.2 build /home/akrueger/node_modules/solgraph
> babel -d dist src

{ Error: Cannot find module '@babel/preset-es2015' from '/home/akrueger/node_modules/solgraph'
    at Function.module.exports [as sync] (/home/akrueger/node_modules/resolve/lib/sync.js:43:15)
    at resolveStandardizedName (/home/akrueger/node_modules/@babel/core/lib/config/files/plugins.js:101:31)
    at resolvePreset (/home/akrueger/node_modules/@babel/core/lib/config/files/plugins.js:58:10)
    at loadPreset (/home/akrueger/node_modules/@babel/core/lib/config/files/plugins.js:77:20)
    at createDescriptor (/home/akrueger/node_modules/@babel/core/lib/config/config-descriptors.js:114:9)
    at items.map (/home/akrueger/node_modules/@babel/core/lib/config/config-descriptors.js:69:50)
    at Array.map (<anonymous>)
    at createDescriptors (/home/akrueger/node_modules/@babel/core/lib/config/config-descriptors.js:69:29)
    at createPresetDescriptors (/home/akrueger/node_modules/@babel/core/lib/config/config-descriptors.js:61:10)
    at presets (/home/akrueger/node_modules/@babel/core/lib/config/config-descriptors.js:43:19) code: 'MODULE_NOT_FOUND' }
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! solgraph@0.3.2 build: `babel -d dist src`
npm ERR! Exit status 1
npm ERR! 
npm ERR! Failed at the solgraph@0.3.2 build script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm WARN Local package.json exists, but node_modules missing, did you mean to install?

npm ERR! A complete log of this run can be found in:
npm ERR!     /home/akrueger/.npm/_logs/2018-08-06T13_00_18_382Z-debug.log
npm WARN enoent ENOENT: no such file or directory, open '/home/akrueger/package.json'
npm WARN akrueger No description
npm WARN akrueger No repository field.
npm WARN akrueger No README data
npm WARN akrueger No license field.
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.4 (node_modules/fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.4: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})

npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! solgraph@0.3.2 postinstall: `npm run build`
npm ERR! Exit status 1
npm ERR! 
npm ERR! Failed at the solgraph@0.3.2 postinstall script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     /home/akrueger/.npm/_logs/2018-08-06T13_00_18_910Z-debug.log

@raineorshine
Copy link
Owner

@drandreaskrueger Can you try this?

sudo npm install -g solgraph --unsafe-perm=true --allow-root

@drandreaskrueger
Copy link
Author

sudo npm install -g solgraph --unsafe-perm=true --allow-root
npm WARN deprecated @babel/preset-es2015@7.0.0-beta.53: 👋 We've deprecated any official yearly presets in 6.x in favor or babel-preset-env. For 7.x it would be @babel/preset-env.
/usr/local/bin/solgraph -> /usr/local/lib/node_modules/solgraph/solgraph.js

> solgraph@0.3.2 postinstall /usr/local/lib/node_modules/solgraph
> npm run build


> solgraph@0.3.2 build /usr/local/lib/node_modules/solgraph
> babel -d dist src

{ Error: Cannot find module '@babel/preset-es2015' from '/usr/local/lib/node_modules/solgraph'
    at Function.module.exports [as sync] (/usr/local/lib/node_modules/solgraph/node_modules/resolve/lib/sync.js:43:15)
    at resolveStandardizedName (/usr/local/lib/node_modules/solgraph/node_modules/@babel/core/lib/config/files/plugins.js:101:31)
    at resolvePreset (/usr/local/lib/node_modules/solgraph/node_modules/@babel/core/lib/config/files/plugins.js:58:10)
    at loadPreset (/usr/local/lib/node_modules/solgraph/node_modules/@babel/core/lib/config/files/plugins.js:77:20)
    at createDescriptor (/usr/local/lib/node_modules/solgraph/node_modules/@babel/core/lib/config/config-descriptors.js:114:9)
    at items.map (/usr/local/lib/node_modules/solgraph/node_modules/@babel/core/lib/config/config-descriptors.js:69:50)
    at Array.map (<anonymous>)
    at createDescriptors (/usr/local/lib/node_modules/solgraph/node_modules/@babel/core/lib/config/config-descriptors.js:69:29)
    at createPresetDescriptors (/usr/local/lib/node_modules/solgraph/node_modules/@babel/core/lib/config/config-descriptors.js:61:10)
    at presets (/usr/local/lib/node_modules/solgraph/node_modules/@babel/core/lib/config/config-descriptors.js:43:19) code: 'MODULE_NOT_FOUND' }
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! solgraph@0.3.2 build: `babel -d dist src`
npm ERR! Exit status 1
npm ERR! 
npm ERR! Failed at the solgraph@0.3.2 build script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     /root/.npm/_logs/2018-08-20T07_57_27_556Z-debug.log
npm WARN @babel/preset-es2015@7.0.0-beta.53 requires a peer of @babel/core@>=7.0.0-beta.50 <7.0.0-rc.0 but none is installed. You must install peer dependencies yourself.
npm WARN @babel/plugin-transform-arrow-functions@7.0.0-beta.53 requires a peer of @babel/core@>=7.0.0-beta.50 <7.0.0-rc.0 but none is installed. You must install peer dependencies yourself.
npm WARN @babel/plugin-transform-block-scoped-functions@7.0.0-beta.53 requires a peer of @babel/core@>=7.0.0-beta.50 <7.0.0-rc.0 but none is installed. You must install peer dependencies yourself.
npm WARN @babel/plugin-transform-destructuring@7.0.0-beta.53 requires a peer of @babel/core@>=7.0.0-beta.50 <7.0.0-rc.0 but none is installed. You must install peer dependencies yourself.
npm WARN @babel/plugin-transform-computed-properties@7.0.0-beta.53 requires a peer of @babel/core@>=7.0.0-beta.50 <7.0.0-rc.0 but none is installed. You must install peer dependencies yourself.
npm WARN @babel/plugin-transform-duplicate-keys@7.0.0-beta.53 requires a peer of @babel/core@>=7.0.0-beta.50 <7.0.0-rc.0 but none is installed. You must install peer dependencies yourself.
npm WARN @babel/plugin-transform-function-name@7.0.0-beta.53 requires a peer of @babel/core@>=7.0.0-beta.50 <7.0.0-rc.0 but none is installed. You must install peer dependencies yourself.
npm WARN @babel/plugin-transform-block-scoping@7.0.0-beta.53 requires a peer of @babel/core@>=7.0.0-beta.50 <7.0.0-rc.0 but none is installed. You must install peer dependencies yourself.
npm WARN @babel/plugin-transform-classes@7.0.0-beta.53 requires a peer of @babel/core@>=7.0.0-beta.50 <7.0.0-rc.0 but none is installed. You must install peer dependencies yourself.
npm WARN @babel/plugin-transform-instanceof@7.0.0-beta.53 requires a peer of @babel/core@>=7.0.0-beta.50 <7.0.0-rc.0 but none is installed. You must install peer dependencies yourself.
npm WARN @babel/plugin-transform-literals@7.0.0-beta.53 requires a peer of @babel/core@>=7.0.0-beta.50 <7.0.0-rc.0 but none is installed. You must install peer dependencies yourself.
npm WARN @babel/plugin-transform-for-of@7.0.0-beta.53 requires a peer of @babel/core@>=7.0.0-beta.50 <7.0.0-rc.0 but none is installed. You must install peer dependencies yourself.
npm WARN @babel/plugin-transform-modules-umd@7.0.0-beta.53 requires a peer of @babel/core@>=7.0.0-beta.50 <7.0.0-rc.0 but none is installed. You must install peer dependencies yourself.
npm WARN @babel/plugin-transform-object-super@7.0.0-beta.53 requires a peer of @babel/core@>=7.0.0-beta.50 <7.0.0-rc.0 but none is installed. You must install peer dependencies yourself.
npm WARN @babel/plugin-transform-modules-systemjs@7.0.0-beta.53 requires a peer of @babel/core@>=7.0.0-beta.50 <7.0.0-rc.0 but none is installed. You must install peer dependencies yourself.
npm WARN @babel/plugin-transform-modules-commonjs@7.0.0-beta.53 requires a peer of @babel/core@>=7.0.0-beta.50 <7.0.0-rc.0 but none is installed. You must install peer dependencies yourself.
npm WARN @babel/plugin-transform-modules-amd@7.0.0-beta.53 requires a peer of @babel/core@>=7.0.0-beta.50 <7.0.0-rc.0 but none is installed. You must install peer dependencies yourself.
npm WARN @babel/plugin-transform-shorthand-properties@7.0.0-beta.53 requires a peer of @babel/core@>=7.0.0-beta.50 <7.0.0-rc.0 but none is installed. You must install peer dependencies yourself.
npm WARN @babel/plugin-transform-regenerator@7.0.0-beta.53 requires a peer of @babel/core@>=7.0.0-beta.50 <7.0.0-rc.0 but none is installed. You must install peer dependencies yourself.
npm WARN @babel/plugin-transform-sticky-regex@7.0.0-beta.53 requires a peer of @babel/core@>=7.0.0-beta.50 <7.0.0-rc.0 but none is installed. You must install peer dependencies yourself.
npm WARN @babel/plugin-transform-spread@7.0.0-beta.53 requires a peer of @babel/core@>=7.0.0-beta.50 <7.0.0-rc.0 but none is installed. You must install peer dependencies yourself.
npm WARN @babel/plugin-transform-parameters@7.0.0-beta.53 requires a peer of @babel/core@>=7.0.0-beta.50 <7.0.0-rc.0 but none is installed. You must install peer dependencies yourself.
npm WARN @babel/plugin-transform-template-literals@7.0.0-beta.53 requires a peer of @babel/core@>=7.0.0-beta.50 <7.0.0-rc.0 but none is installed. You must install peer dependencies yourself.
npm WARN @babel/plugin-transform-typeof-symbol@7.0.0-beta.53 requires a peer of @babel/core@>=7.0.0-beta.50 <7.0.0-rc.0 but none is installed. You must install peer dependencies yourself.
npm WARN @babel/plugin-transform-unicode-regex@7.0.0-beta.53 requires a peer of @babel/core@>=7.0.0-beta.50 <7.0.0-rc.0 but none is installed. You must install peer dependencies yourself.
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.4 (node_modules/solgraph/node_modules/fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.4: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})

npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! solgraph@0.3.2 postinstall: `npm run build`
npm ERR! Exit status 1
npm ERR! 
npm ERR! Failed at the solgraph@0.3.2 postinstall script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     /root/.npm/_logs/2018-08-20T07_57_28_045Z-debug.log

@raineorshine
Copy link
Owner

@drandreaskrueger Just fixed the babel error and published to v0.3.3

@drandreaskrueger
Copy link
Author

sudo npm install -g solgraph --unsafe-perm=true --allow-root
/usr/local/bin/solgraph -> /usr/local/lib/node_modules/solgraph/solgraph.js

> solgraph@0.3.3 postinstall /usr/local/lib/node_modules/solgraph
> npm run build


> solgraph@0.3.3 build /usr/local/lib/node_modules/solgraph
> babel -d dist src

Successfully compiled 2 files with Babel.
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.4 (node_modules/solgraph/node_modules/fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.4: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})

+ solgraph@0.3.3
added 338 packages from 430 contributors in 9.956s

@drandreaskrueger
Copy link
Author

this now seems to work fine:

git clone https://github.com/raiden-network/raiden-contracts raiden-network_raiden-contracts
cd raiden-network_raiden-contracts/raiden_contracts/contracts/
find . -type f -name "*.sol" -printf "solgraph %p > %p.dot\n" | bash
find . -type f -name "*.dot" -printf "dot -Tpng %p > %p.png\n" | bash

and there is one png file for each sol file:

find . -type f -name "*.sol" | wc
     17      17     442
find . -type f -name "*.png" | wc
     17      17     578

@drandreaskrueger
Copy link
Author

drandreaskrueger commented Aug 21, 2018

Thanks!!

@sharadkapilsharma
Copy link

Hi,
I am referring [https://github.com/raineorshine/solgraph]

sudo npm install -g solgraph --unsafe-perm=true --allow-root is producing am following error:

| |---------------------------------------------------------------------------------------------------------------------------------------|
WARN engine solgraph@0.3.3: wanted: {"node":">=6"} (current: {"node":"4.2.6","npm":"3.5.2"})
loadDep:solidity-parser-s / |#######################--------------------------------------------------------------------------------------|
loadDep:chokidar -> addNa | |#######################--------------------------------------------------------------------------------------|
loadDep:urix -> afterAdd \ |#######################--------------------------------------------------------------------------------------|
loadDep:semver -> get - |#########################------------------------------------------------------------------------------------|
loadDep:source-map-suppor - |#############################--------------------------------------------------------------------------------|
/usr/local/bin/solgraph -> /usr/local/lib/node_modules/solgraph/solgraph.js

solgraph@0.3.3 postinstall /usr/local/lib/node_modules/solgraph
npm run build

solgraph@0.3.3 build /usr/local/lib/node_modules/solgraph
babel -d dist src

/usr/local/lib/node_modules/solgraph/node_modules/@babel/core/lib/transformation/file/file.js:75
constructor(options, {
^

SyntaxError: Unexpected token {
at exports.runInThisContext (vm.js:53:16)
at Module._compile (module.js:374:25)
at Object.Module._extensions..js (module.js:417:10)
at Module.load (module.js:344:32)
at Function.Module._load (module.js:301:12)
at Module.require (module.js:354:17)
at require (internal/module.js:12:17)
at Object. (/usr/local/lib/node_modules/solgraph/node_modules/@babel/core/lib/index.js:147:36)
at Module._compile (module.js:410:26)
at Object.Module._extensions..js (module.js:417:10)

npm ERR! Linux 4.10.0-35-generic
npm ERR! argv "/usr/bin/nodejs" "/usr/bin/npm" "run" "build"
npm ERR! node v4.2.6
npm ERR! npm v3.5.2
npm ERR! code ELIFECYCLE
npm ERR! solgraph@0.3.3 build: babel -d dist src
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the solgraph@0.3.3 build script 'babel -d dist src'.
npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the solgraph package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! babel -d dist src
npm ERR! You can get information on how to open an issue for this project with:
npm ERR! npm bugs solgraph
npm ERR! Or if that isn't available, you can get their info via:
npm ERR! npm owner ls solgraph
npm ERR! There is likely additional logging output above.

npm ERR! Please include the following file with any support request:
npm ERR! /usr/local/lib/node_modules/solgraph/npm-debug.log
npm WARN optional Skipping failed optional dependency /solgraph/chokidar/fsevents:
npm WARN notsup Not compatible with your operating system or architecture: fsevents@1.2.4
npm ERR! Linux 4.10.0-35-generic
npm ERR! argv "/usr/bin/nodejs" "/usr/bin/npm" "install" "-g" "solgraph" "--unsafe-perm=true" "--allow-root"
npm ERR! node v4.2.6
npm ERR! npm v3.5.2
npm ERR! code ELIFECYCLE

npm ERR! solgraph@0.3.3 postinstall: npm run build
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the solgraph@0.3.3 postinstall script 'npm run build'.
npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the solgraph package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! npm run build
npm ERR! You can get information on how to open an issue for this project with:
npm ERR! npm bugs solgraph
npm ERR! Or if that isn't available, you can get their info via:
npm ERR! npm owner ls solgraph
npm ERR! There is likely additional logging output above.

npm ERR! Please include the following file with any support request:
npm ERR! /home/sharadsharma/work/solgraph/npm-debug.log

I tried many times, but facing same issue.

Please suggest.
Thanks

@raineorshine
Copy link
Owner

@sharadkapilsharma solgraph requires node >= 6

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

No branches or pull requests

3 participants