I just updated npm to 5.4.0. Now, Whenever I want install a npm package I get the following error:
npm
5.4.0
D:\\Sources\\DownloadCms\\Md
Mine was as a result of opening my project folder a 2 different terminals. I solved it by closing all running terminal (vs code was excluded) and executing the installation command again.
I hope this helps someone.
NB: deleting node_modules didn't solve it.