federicobond / solcheck

A Solidity linter written in JS
GNU General Public License v3.0
32 stars 7 forks source link

TypeError: Object.entries is not a function #26

Open HaleTom opened 6 years ago

HaleTom commented 6 years ago

My solcheck is installed globally, as is the npm recommendation for anything run from the command line.

I'm seeing this:

$ solcheck Adoption.sol
/home/ravi/.local/share/npm/lib/node_modules/solcheck/lib/linter.js:71
    return Object.entries(require("./rules"));
                  ^

TypeError: Object.entries is not a function
    at Linter.getRules (/home/ravi/.local/share/npm/lib/node_modules/solcheck/lib/linter.js:71:19)
    at Linter.verify (/home/ravi/.local/share/npm/lib/node_modules/solcheck/lib/linter.js:104:41)
    at verify (/home/ravi/.local/share/npm/lib/node_modules/solcheck/lib/index.js:44:33)
    at /home/ravi/.local/share/npm/lib/node_modules/solcheck/lib/index.js:35:22
    at f (/home/ravi/.local/share/npm/lib/node_modules/once/once.js:25:25)
    at Glob.<anonymous> (/home/ravi/.local/share/npm/lib/node_modules/glob/glob.js:151:7)
    at emitOne (events.js:96:13)
    at Glob.emit (events.js:188:7)
    at Glob._finish (/home/ravi/.local/share/npm/lib/node_modules/glob/glob.js:197:8)
    at done (/home/ravi/.local/share/npm/lib/node_modules/glob/glob.js:182:14)
federicobond commented 6 years ago

This is likely due to an outdated node version. Will see if I can change the Babel preset to account for ths.