hypercore-protocol / cli

A CLI for peer-to-peer file sharing using the Hypercore Protocol.
MIT License
206 stars 17 forks source link

Syntax Error #35

Closed hiswillbedun closed 3 years ago

hiswillbedun commented 3 years ago

I have installed, removed and reinstalled hyp and still getting same error. When installing, I receive several warnings about deprecated components. However it finishes install. Once I enter hyp daemon start or any other command beginning with hyp, I get the following. OS is KDE Neon 5.20.


/usr/local/lib/node_modules/@hyperspace/cli/bin/hyp.js:6
import subcommand from 'subcommand'
       ^^^^^^^^^^

SyntaxError: Unexpected identifier
    at Module._compile (internal/modules/cjs/loader.js:723:23)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:789:10)
    at Module.load (internal/modules/cjs/loader.js:653:32)
    at tryModuleLoad (internal/modules/cjs/loader.js:593:12)
    at Function.Module._load (internal/modules/cjs/loader.js:585:3)
    at Function.Module.runMain (internal/modules/cjs/loader.js:831:12)
    at startup (internal/bootstrap/node.js:283:19)
    at bootstrapNodeJSCore (internal/bootstrap/node.js:623:3)```

Here are the warnings I get while installing.

```$ sudo npm install -g @hyperspace/cli
npm WARN deprecated debug@3.2.6: Debug versions >=3.2.0 <3.2.7 || >=4 <4.3.1 have a low-severity ReDos regression when used in a Node.js environment. It is recommended you upgrade to 3.2.7 or 4.3.1. (https://github.com/visionmedia/debug/issues/797)
npm WARN deprecated fsevents@2.1.3: "Please update to latest v2.3 or v2.2"
npm WARN deprecated cross-spawn-async@2.2.5: cross-spawn no longer requires a build toolchain, use it instead
/usr/local/bin/hyp -> /usr/local/lib/node_modules/@hyperspace/cli/bin/hyp.js

> fd-lock@1.1.1 install /usr/local/lib/node_modules/@hyperspace/cli/node_modules/fd-lock
> node-gyp-build```

Any assistance would be greatly appreciated!
pfrazee commented 3 years ago

Hi, sorry for the delay- are you using node 14+? That's required. Latest hyp cli release will now tell you if you're using too old a node version.

hiswillbedun commented 3 years ago

I am actually using the latest version available. was 15.x

On Tue, Jan 26, 2021 at 9:33 AM Paul Frazee notifications@github.com wrote:

Hi, sorry for the delay- are you using node 14+? That's required. Latest hyp cli release will now tell you if you're using too old a node version.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/hypercore-protocol/cli/issues/35#issuecomment-767580692, or unsubscribe https://github.com/notifications/unsubscribe-auth/ALHZUXS554DFSRJGFKMZNSDS33HD5ANCNFSM4WLOYAIA .

pfrazee commented 3 years ago

Hmm, that's surprising. I'm not sure why you'd see that error then.

hiswillbedun commented 3 years ago

Was actually giving thought to wiping my system due to other issues and installing fresh. You can close the ticket for now. If I still have issues, I will reopen it.

On Tue, Jan 26, 2021 at 9:41 AM Paul Frazee notifications@github.com wrote:

Hmm, that's surprising. I'm not sure why you'd see that error then.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/hypercore-protocol/cli/issues/35#issuecomment-767588525, or unsubscribe https://github.com/notifications/unsubscribe-auth/ALHZUXVBXDC4XDCC5YBKHXTS33IBTANCNFSM4WLOYAIA .

pfrazee commented 3 years ago

Okay, if anybody else experiences this please reopen!