Reputation: 45
I am facing this issue:
error An unexpected error occurred: "/home/vagrant/.cache/yarn/v1/npm-cors-2.8.4-2bd381f2eb201020105cd50ea59da63090694686/.yarn-metadata.json: Unexpected end of JSON input".
A few things to note:
During the installation of cors (yarn add cors
), my laptop died on battery.
The cors files are there in node modules but aren't listed in package.json.
I recently switched from npm to yarn and operate within vagrant VM.
Tried to delete files from node modules but id didn't make a difference
yarn remove cors
gives this error:
error This module isn't specified in a manifest.
Upvotes: 1
Views: 3329
Reputation: 800
Seems like you've got broken yarn cache. Execute yarn cache clean
and retry module installation.
Upvotes: 2