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

yarn create next-app and run not work as expected #32721

Closed
1095533987 opened this issue Dec 22, 2021 · 2 comments
Closed

yarn create next-app and run not work as expected #32721

1095533987 opened this issue Dec 22, 2021 · 2 comments
Labels
bug Issue was opened via the bug report template.

Comments

@1095533987
Copy link

What version of Next.js are you using?

12.0.7 or 12.0.5

What version of Node.js are you using?

16.13.0

What browser are you using?

Chrome

What operating system are you using?

Windows

How are you deploying your application?

next dev

Describe the Bug

I just follow the steps on the official website, as follows:
yarn create next-app
yarn dev

then, the following error message appears.

ready - started server on 0.0.0.0:3000, url: http://localhost:3000
error - ./.yarn/virtual/next-virtual-82b09e8a3c/0/cache/next-npm-12.0.7-4cffaa57c8-78a0ebd697.zip/node_modules/next/dist/client/dev/amp-dev.js
Error: Failed to read source code from E:\project\my-app.yarn_virtual_\next-virtual-82b09e8a3c\0\cache\next-npm-12.0.7-4cffaa57c8-78a0ebd697.zip\node_modules\next\dist\client\dev\amp-dev.js

wait - compiling...
error - ./.yarn/virtual/next-virtual-82b09e8a3c/0/cache/next-npm-12.0.7-4cffaa57c8-78a0ebd697.zip/node_modules/next/dist/client/dev/webpack-hot-middleware-client.js
Error: Failed to read source code from E:\project\my-app.yarn_virtual_\next-virtual-82b09e8a3c\0\cache\next-npm-12.0.7-4cffaa57c8-78a0ebd697.zip\node_modules\next\dist\client\dev\webpack-hot-middleware-client.js

wait - compiling...
error - ./.yarn/virtual/next-virtual-82b09e8a3c/0/cache/next-npm-12.0.7-4cffaa57c8-78a0ebd697.zip/node_modules/next/dist/client/dev/webpack-hot-middleware-client.js
Error: Failed to read source code from E:\project\my-app.yarn_virtual_\next-virtual-82b09e8a3c\0\cache\next-npm-12.0.7-4cffaa57c8-78a0ebd697.zip\node_modules\next\dist\client\dev\webpack-hot-middleware-client.js

Expected Behavior

no error message.

To Reproduce

yarn create next-app
yarn dev

@1095533987 1095533987 added the bug Issue was opened via the bug report template. label Dec 22, 2021
@kaykdm kaykdm mentioned this issue Dec 28, 2021
10 tasks
kodiakhq bot pushed a commit that referenced this issue Jan 11, 2022
x-ref [#31552 ](#31552)
x-ref #32115
x-ref #32546
x-ref #32721

Since this PR #31455 is merged, `enhanced-resolve` dependency's resolved field is changed which caused broken yarn pnp.
I am not sure how this field has been changed or this is intentional or not 
When I install webpack locally, `enhanced-resolve`'s resolved field in lock file is always `registry.yarnpkg.com` not `codeload.github.com`

## Bug

- [x] Related issues linked using `fixes #number`
- [ ] Integration tests added
- [ ] Errors have helpful link attached, see `contributing.md`

## Feature

- [ ] Implements an existing feature request or RFC. Make sure the feature request has been accepted for implementation before opening a PR.
- [ ] Related issues linked using `fixes #number`
- [ ] Integration tests added
- [ ] Documentation added
- [ ] Telemetry added. In case of a feature if it's used or not.
- [ ] Errors have helpful link attached, see `contributing.md`

## Documentation / Examples

- [ ] Make sure the linting passes by running `yarn lint`


Co-authored-by: Tobias Koppers <1365881+sokra@users.noreply.github.com>
Co-authored-by: JJ Kasper <22380829+ijjk@users.noreply.github.com>
@rtritto
Copy link

rtritto commented Jan 13, 2022

Duplicate of #31812
It will be fixed with #33236

@balazsorban44
Copy link
Member

This issue has been automatically locked due to no recent activity. If you are running into a similar issue, please create a new issue with the steps to reproduce. Thank you.

@vercel vercel locked as resolved and limited conversation to collaborators Feb 13, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Issue was opened via the bug report template.
Projects
None yet
Development

No branches or pull requests

3 participants