Skip to content

Flow doesn't work with npm v5.4.0 #4733

@someden

Description

@someden

Is this a bug report?

Yes

Can you also reproduce the problem with npm 4.x?

There is no problem with npm 4.x and 5.3.0, only with npm 5.4.0.

Environment

node -v: v8.4.0
npm -v: v5.4.0
npm ls react-scripts: I tried with 1.0.10, 1.0.11 and 1.0.12
npm ls flow-bin: I tried with 0.52.0 and 0.53.1
Operating system: macOS Sierra v10.12.6

Steps to Reproduce

  1. In Terminal:
$ create-react-app test-flow
$ cd test-flow
$ npm install --save-dev flow-bin
  1. Add "flow": "flow" to the scripts section of your package.json.
  2. Run npm run flow init
  3. And you will see the error:
> test-flow@0.1.0 flow /Users/admin/Sites/test-flow
> flow "init"

internal/child_process.js:325
    throw errnoException(err, 'spawn');
    ^

Error: spawn EACCES
    at _errnoException (util.js:1041:11)
    at ChildProcess.spawn (internal/child_process.js:325:11)
    at exports.spawn (child_process.js:493:9)
    at Object.<anonymous> (/Users/admin/Sites/test-flow/node_modules/flow-bin/cli.js:17:3)
    at Module._compile (module.js:573:30)
    at Object.Module._extensions..js (module.js:584:10)
    at Module.load (module.js:507:32)
    at tryModuleLoad (module.js:470:12)
    at Function.Module._load (module.js:462:3)
    at Function.Module.runMain (module.js:609:10)
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! test-flow@0.1.0 flow: `flow "init"`
npm ERR! Exit status 1
npm ERR! 
npm ERR! Failed at the test-flow@0.1.0 flow script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

Flow worked good a few days ago (with react-scripts 1.0.10), but now it doesn't work (even with react-scripts 1.0.10).

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions