question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Yarn PnP Compatibility

See original GitHub issue

Is this a bug report?

Yes

Clone DanielRuf/coding-coach, checkout the feature/yarn-pnp branch and install with Yarn nightly and run yarn start.

Module build failed: Error: Failed to load plugin flowtype: Package "eslint@4.10.0" (via "/Users/druf/Library/Caches/Yarn/v3/npm-eslint-4.10.0-f25d0d7955c81968c2309aa5c9a229e045176bb7/node_modules/eslint/lib/config/plugins.js") is trying to require the package "eslint-plugin-flowtype" (via "eslint-plugin-flowtype") without it being listed in its dependencies (ajv, babel-code-frame, chalk, concat-stream, cross-spawn, debug, doctrine, eslint-scope, espree, esquery, estraverse, esutils, file-entry-cache, functional-red-black-tree, glob, globals, ignore, imurmurhash, inquirer, is-resolvable, js-yaml, json-stable-stringify, levn, lodash, minimatch, mkdirp, natural-compare, optionator, path-is-inside, pluralize, progress, require-uncached, semver, strip-ansi, strip-json-comments, table, text-table, eslint)
Referenced from: 
    at Array.forEach (<anonymous>)
    at Array.reduceRight (<anonymous>)

Did you try recovering your dependencies?

Not needed as this is a clean install.

Which terms did you search for in User Guide?

Environment

The project uses react-scripts@1.1.5.

(paste the output of the command here)

Steps to Reproduce

Clone DanielRuf/coding-coach, checkout the feature/yarn-pnp branch and install with Yarn nightly and run yarn start.

  1. Clone DanielRuf/coding-coach
  2. checkout the feature/yarn-pnp branch
  3. install Yarn nightly
  4. run yarn && yarn start

Expected Behavior

(Write what you thought would happen.)

It should run without any errors.

Actual Behavior

I’ve got

Module build failed: Error: Failed to load plugin flowtype: Package "eslint@4.10.0" (via "/Users/druf/Library/Caches/Yarn/v3/npm-eslint-4.10.0-f25d0d7955c81968c2309aa5c9a229e045176bb7/node_modules/eslint/lib/config/plugins.js") is trying to require the package "eslint-plugin-flowtype" (via "eslint-plugin-flowtype") without it being listed in its dependencies (ajv, babel-code-frame, chalk, concat-stream, cross-spawn, debug, doctrine, eslint-scope, espree, esquery, estraverse, esutils, file-entry-cache, functional-red-black-tree, glob, globals, ignore, imurmurhash, inquirer, is-resolvable, js-yaml, json-stable-stringify, levn, lodash, minimatch, mkdirp, natural-compare, optionator, path-is-inside, pluralize, progress, require-uncached, semver, strip-ansi, strip-json-comments, table, text-table, eslint)
Referenced from: 
    at Array.forEach (<anonymous>)
    at Array.reduceRight (<anonymous>)

Reproducible Demo

(Paste the link to an example project and exact instructions to reproduce the issue.)

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:9 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
arcaniscommented, Sep 27, 2018
  • A Yarn bug was preventing webpack-dev-middleware to access webpack - will be fixed with https://github.com/yarnpkg/yarn/pull/6443

  • A dependency was missing from react-dev-utils - fixed with #5134

  • The pnp-webpack-plugin was missing - will be fixed with #5136

  • The thread-loader package doesnt forward process.execArgv to the spawned threads, preventing them from loading their dependencies since the hook isn’t setup in their environment - will be fixed with #5136

0reactions
arcaniscommented, Sep 27, 2018

Looking 👍

Read more comments on GitHub >

github_iconTop Results From Across the Web

Plug'n'Play | Yarn - Package Manager
Yarn Plug'n'Play provides semantic errors (explaining you the exact reason why a package isn't reachable from another) and a sensible JS API to...
Read more >
What is Yarn PNP and Should You Use It? - Atomic Spin
The first thing to consider is that not all libraries are compatible with the illusion Yarn is presenting with PNP.
Read more >
Compatibility with yarn 2 (or yarn 1 PnP mode) #458 - GitHub
Current Behavior. Yarn v2 got a stable release today, and it uses PnP (instead of node_modules) exclusively
Read more >
Yarn v2 PnP is simply a lifesaver if you have a medium+ sized ...
Pnpm is indeed better than npm but I found it's symlinking approach less compatible than yarn v2, (nextJS for example didn't support pnpm...
Read more >
Compatibililty with Yarn PnP (Plug and Play) feature - YouTrack
Just wanted to say that PnP will be enabled by default in Yarn v2. It still in development but will likely be released...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found