Skip to content

"No such file" error #5

Closed
Closed

Description

@sendrecv

After npm install hiper -g, hiper baidu.com throws this exception:

/usr/bin/env: 'node --no-warnings': No such file or directory

I'm currently running Node 10 with nvm on Manjaro (Arch) Linux.

Activity

  1. pod4g commented on Jun 5, 2018

    @pod4g
    Owner

    Hi, May be you should run sudo ln -s /usr/bin/nodejs /usr/bin/node

  2. sendrecv commented on Jun 5, 2018

    @sendrecv
    Author

    I think it must be something else. That command returns an error because /usr/bin/node already exists. I currently have node installed with both pacman (because it's a dependency of some locally installed apps like atom) and with nvm, so when I run which node it returns:

    /home/sendrecv/.nvm/versions/node/v10.3.0/bin/node

  3. pod4g commented on Jun 5, 2018

    @pod4g
    Owner

    Try which env and type /usr/bin/env. Then run /usr/bin/env node.

  4. danner26 commented on Jun 5, 2018

    @danner26

    Same issue here, node 10. The env is set properly (I think) and both /usr/bin/env and /usr/bin/env node work by themselves, but not when running hiper

  5. pseudolog commented on Jun 6, 2018

    @pseudolog

    Hi, was just gonna report that myself. The problem lies within your shebang.

    #! /usr/bin/env node --no-warnings

    Linux (unlike BSD it seems) doesn't support more than one argument to the shebang command. (Details)

    Get rid of the --no-warnings argument and it should function properly. node added support for a NODE_NO_WARNINGS environment variable. Maybe use that as a workaround?

  6. danner26 commented on Jun 6, 2018

    @danner26

    @pseudolog has it right, remove the --no-warnings and it will work correctly

    and I agree with the NODE_NO_WARNINGS env variable as a work around, I think that would be the best course of action

  7. pod4g commented on Jun 6, 2018

    @pod4g
    Owner

    @pseudolog Well done!!!!

  8. pod4g commented on Jun 6, 2018

    @pod4g
    Owner

    Hi guys.

    I change the code of hiper/src/index.js as follow. The warning message will still appear

    #! /usr/bin/env node
    process.env.NODE_NO_WARNINGS = 1

    Can someone help me?

  9. zhiyan commented on Jun 7, 2018

    @zhiyan
    Contributor

    Maybe add a shell wrapper, instead of excute the index.js directly.

  10. pseudolog commented on Jun 7, 2018

    @pseudolog

    I guess the cleanest solution would be to actually handle those promise rejections. Otherwise there's process.removeAllListeners('warning')

  11. pod4g commented on Jun 8, 2018

    @pod4g
    Owner

    @zhiyan Please give me more details. what should i do?

  12. added a commit that references this issue on Jun 8, 2018
  13. pod4g commented on Jun 8, 2018

    @pod4g
    Owner

    The problem has been solved, please upgrade hiper to 0.0.15

    run below to upgrade:

    npm i hiper -g

    thr pr: #21

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    help wantedExtra attention is needed

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions