Npm cache contains wrong version

npm

#1

Hi,

We have a JS project that depends on react “15.3.2” and on material-ui “0.16.1”. material-ui, in turn, depends on react “^15.0.0”. When installing on Circle, we get

$ npm ls react
web@0.0.1 /home/ubuntu/web
├─┬ material-ui@0.16.1
│ ├── react@15.4.2
│ └─┬ react-event-listener@0.4.0
│   └── react@15.4.2
└── react@15.3.2

Which leads to all kinds of trouble. material-ui’s dependency on react “^15.0.0” could be satisfied by react 15.3.2, which is also what happens when I run this locally.

Also, if I try to rebuild without cache, I get the expected

$ npm ls react
web@0.0.1 /home/ubuntu/web
└── react@15.3.2

So I suspect your npm cache somehow chooses the wrong react?


#2