Yarn: Error running Yarn due to new `node-emoji` entry point

Created on 2 Dec 2016  路  6Comments  路  Source: yarnpkg/yarn

Do you want to request a feature or report a bug?
Bug

What is the current behavior?
I use npm i -g yarn to install and upgrade Yarn. When I ran this command today, then tried to use the Yarn CLI, I received the following error:

...
Error: ENOENT: no such file or directory, open 'GLOBAL_NODE_MODULES_PATH/yarn/node_modules/node-emoji/index.js'
...

It looks like the node-emoji package restructured its entry point in this commit and then released that in version 1.4.2 earlier today. However, Yarn still seems to be looking for index.js.

If the current behavior is a bug, please provide the steps to reproduce.

  1. npm i -g yarn
  2. yarn ...

What is the expected behavior?
Yarn should work as normal, e.g. yarn or yarn install should run without a node-emoji error.

Please mention your node.js, yarn and operating system version.
Node v7.2.0
Yarn v0.17.10
macOS Sierra v10.12.1

Most helpful comment

This is a known issue, I added a cache breaker in #1965 which should be in latest, if it's not then it'll be in the next release. The fix here is to remove the Yarn cache, one of the following commands should work:

# OSX
$ rm -rf ~/Library/Caches/Yarn

# Linux
$ rm -rf ~/.cache/yarn

# Windows
$ del %LOCALAPPDATA%/Yarn/cache

All 6 comments

Mentioned this in #2072, likely related? (but probably worth tracking separately)

+1 here, same problem just 20 minutes ago.

Node v7.2.0
Yarn v0.17.10
Debian Jessie

I'm also getting this across at least 3 machines.
[edited]
Upgrading to yarn 0.17.10 fixed it for me (I also cleared out the yarn cache and reinstalled yarn & node_modules from scratch so those may have also contributed).

FWIW, I uninstalled yarn, blew away the yarn cache, blew away the npm cache, reinstalled via npm and it seems to be ok now.

Possibly some sort of yarn cache issue?

This is a known issue, I added a cache breaker in #1965 which should be in latest, if it's not then it'll be in the next release. The fix here is to remove the Yarn cache, one of the following commands should work:

# OSX
$ rm -rf ~/Library/Caches/Yarn

# Linux
$ rm -rf ~/.cache/yarn

# Windows
$ del %LOCALAPPDATA%/Yarn/cache

Cool, works for me. Thank you!

Was this page helpful?
0 / 5 - 0 ratings