Yarn returning error while trying to add "Cors"

Asked

Viewed 856 times

-1

This is Devs :D

I’m having a mistake that’s bothering me a little...

When trying to add the "Cors" package by Yarn, the terminal returns me the following error:

$ yarn add cors
yarn add v1.16.0
[1/4] Resolving packages...
[2/4] Fetching packages...
info [email protected]: The platform "win32" is incompatible with this module.
info "[email protected]" is an optional dependency and failed compatibility check. Excluding it from installation.
[3/4] Linking dependencies...
error An unexpected error occurred: "EPERM: operation not permitted, unlink 'E:\\RafaWorks\\CURSOS\\OMNI Stack Aulas\\backend\\node_modules\\sharp\\
build\\Release\\libcroco-0.6-3.dll'".
info If you think this is a bug, please open a bug report with the information provided in "E:\\RafaWorks\\CURSOS\\OMNI Stack Aulas\\backend\\yarn-e
rror.log".
info Visit https://yarnpkg.com/en/docs/cli/add for documentation about this command.

I don’t understand why there is an incompatibility error and I can’t find the solution.

Thank you in advance for your attention!

1 answer

0


Good morning to all,

discovered this morning the problem, was a conflict that existed when trying to add the Cors with the yarn dev of nodemon spinning. In case someone has the same problem I had, just stop the terminal running the yarn dev, the installation will go through successfully.

And if the problem still persists, restart the computer, open your terminal as an administrator and try to run the command again in your project folder yarn add cors.

Browser other questions tagged

You are not signed in. Login or sign up in order to post.