Skip to content
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

plugnplayWindowsSupport warning because of drive letter case mismatch #7005

Closed
codepunkt opened this issue Feb 5, 2019 · 4 comments
Closed
Assignees
Labels

Comments

@codepunkt
Copy link
Contributor

codepunkt commented Feb 5, 2019

When running yarn --pnp in directory 'D:\projectName', this pops up:

warning Plug'n'Play on Windows doesn't support the cache and project to be kept on separate drives

The cache directory is configured as 'd:\.yarncache', yarn cache dir returns 'd:\.yarncache\v4'.
Afaik, windows drive letters in paths are case insensitive, but the code around line 400 of src/config.js does not account for that and produce a mismatch between cacheRootFolderDrive and lockfileFolderDrive, resulting in the warning shown above.

It would be nice if this could be fixed.

specs: windows 10, yarn 1.13.0, node 10.15.1

@ghost ghost assigned Daniel15 Feb 5, 2019
@ghost ghost added the triaged label Feb 5, 2019
@codepunkt
Copy link
Contributor Author

codepunkt commented Feb 5, 2019

Even if i do yarn config set cache-dir D:\.yarncache and can read this out well with yarn config get cache-dir, the cache dir drive letter is still lowercase.

see #6447 & #6447 (comment)

/cc @vkrol @jdalton @arcanis

@arcanis
Copy link
Member

arcanis commented Feb 5, 2019

Makes sense to me. Wanna add the toLowerCase here and add an entry in the changelog? 🙂

@codepunkt
Copy link
Contributor Author

@arcanis I'm not sure if and how this could be tested. Just adding the toLowerCase twice like i did in my local cli.js sounds doable.

@arcanis
Copy link
Member

arcanis commented Feb 5, 2019

Yeah, this one will be a pain to test. The best way would be to setup a mock, but that would complexify our whole test infra for a corner case. I'm fine with no tests for this one if Flow passes.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants