-
Notifications
You must be signed in to change notification settings - Fork 2.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
PnP and Flow resolution #6957
Comments
It only works if I manually add this path to |
Oh I see! Yes, sorry I didn't think about mentioning it, but the cache folder must (by design) be included in the Flow-covered paths indeed (ie the Does that make sense? |
@arcanis, it doesn't, should I add all packages manually? |
Maybe a |
Which paths need to be added? This is still erroring for me. .flowconfig
|
didn't spend much time on it but to get everything working running
#!bin/sh
NODE_OPTIONS='' node ./.pnp.js
"scripts": {
"run-flow-as-a-script": "flow"
},
... @arcanis - is all of this required / the recommended way to get things working / recommended workflow in the current state? |
This doesn't make sense, would cache live in project folder? Then what the difference with node_modules? |
@goodmind - i'm far from an authority on this so it would be good if someone can confirm or advise, but my conclusion: yes, this config puts yarn's cache in the project folder - this doesn't seem ideal to me either, but if flow requires your cache is included by design, then i'm not sure you would want to use your global cache. in dev, if you're working on other projects/use global modules etc, then flow will potentially include unrelated code. i think this would still occur (likely slower) using a project-specific cache if you never cleaned it, unless yarn prunes it (?) in CI, you've lost your cache anyway unless you're explicitly preserving it, and in that case the location becomes irrelevant as you can persist and remount it however you choose. i don't know PnP intimately enough to list all the benefits, but unless you're blowing your cache away all the time, you should see a speed up as you're minimizing disk I/O with a warm cache. if rebuilding your cache is time intensive, then you could look into setting up yarn's offline package mirror to minimize network I/O. |
Closing as Flow PnP support is tracked in yarnpkg/berry#634. |
We had this discussion in yarnpkg/website#869 (comment)
Let's track it here
Do you want to request a feature or report a bug? Bug
What is the current behavior?
If the current behavior is a bug, please provide the steps to reproduce.
https://github.com/goodmind/pnp-flow-resolving
What is the expected behavior? Resolving packages
Please mention your node.js, yarn and operating system version.
node v11.7.0
yarn v1.13.0
macOS High Sierra 10.13.6
The text was updated successfully, but these errors were encountered: