Occasionally I’ll be working with a nodejs project and when I attempt to run $ npm install
I’ll see what appears to be an infinite loop with the same package partially installing and then failing over and over.
I found a fix on the npm github issue tracker and I’ve added it here for posterity
rm -rf ~/.npm