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

The turbo package in nextjs 14 has a bug: EPERM: operation not permitted #57581

Closed
1 task done
peymanath opened this issue Oct 27, 2023 · 11 comments · Fixed by #58835
Closed
1 task done

The turbo package in nextjs 14 has a bug: EPERM: operation not permitted #57581

peymanath opened this issue Oct 27, 2023 · 11 comments · Fixed by #58835
Labels
bug Issue was opened via the bug report template. linear: turbopack Confirmed issue that is tracked by the Turbopack team. locked Turbopack Related to Turbopack with Next.js.

Comments

@peymanath
Copy link

peymanath commented Oct 27, 2023

Link to the code that reproduces this issue

https://github.com/peymanath/terxine/tree/nextjs14-turbo

To Reproduce

Hello everyone,
i'm using Turbo in the developer environment nextjs14, but I'm getting the following error.
Has anyone encountered this error?

Note: When I get this error that NEXTjs wants to render my routes.

   ▲ Next.js 14.0.0 (turbo)
   - Local:        http://localhost:3000

 ✓ Ready in 1161ms
 ○ Compiling /branchs/page ...
 ✓ Compiled /branchs/page in 3.9s
 ○ Compiling /_error ...
 ✓ Compiled /_error in 766ms
 ⨯ [Error: EPERM: operation not permitted, rename 'D:\Work\Development\Project\FrontEnd\Terxine\terxine\.next\build-manifest.json.tmp.jazqmzy5ees' -> 'D:\Work\Development\Project\FrontEnd\Terxine\terxine\.next\build-manifest.json'] {
  errno: -4048,
  code: 'EPERM',
  syscall: 'rename',
  path: 'D:\\Work\\Development\\Project\\FrontEnd\\Terxine\\terxine\\.next\\build-manifest.json.tmp.jazqmzy5ees',
  dest: 'D:\\Work\\Development\\Project\\FrontEnd\\Terxine\\terxine\\.next\\build-manifest.json'
}

Current vs. Expected behavior

When I use Turbo, this problem occurs and the fonts of my site do not load and the application does not work properly and it also gives this error, but without Turbopack there is no problem, the application works properly.

image

Verify canary release

  • I verified that the issue exists in the latest Next.js canary release

Provide environment information

Operating System:
  Platform: win32
  Arch: x64
  Version: Windows 10 Pro
Binaries:
  Node: 18.18.1
  npm: N/A
  Yarn: N/A
  pnpm: 8.9.2
Relevant Packages:
  next: 14.0.1-canary.0
  eslint-config-next: 14.0.0
  react: 18.2.0
  react-dom: 18.2.0
  typescript: 5.2.2
Next.js Config:
  output: N/A

Which area(s) are affected? (Select all that apply)

App Router, Turbopack (--turbo)

Additional context

I am using version 13.5, today I wanted to change to 14 and use turbopack and I had this problem. I tested it when I use create-next-app, it works fine, but there is a problem with my project.

PACK-1956

@peymanath peymanath added the bug Issue was opened via the bug report template. label Oct 27, 2023
@github-actions github-actions bot added the Turbopack Related to Turbopack with Next.js. label Oct 27, 2023
@IhsenBouallegue
Copy link

same issue. Tried deleting the .next folder but didn't work. Sadly couldn't create a reproduction repo as I have a lot of code.

@iojcde
Copy link
Contributor

iojcde commented Oct 30, 2023

Seeing similar errors here:

 ⨯ [Error: EPERM: operation not permitted, rename 'C:\Users\jcde0\dksh-website\.next\app-build-manifest.json.tmp.0jdcitichqov' -> 'C:\Users\jcde0\dksh-website\.next\app-build-manifest.json'] {
  errno: -4048,
  code: 'EPERM',
  syscall: 'rename',
  path: 'C:\\Users\\jcde0\\dksh-website\\.next\\app-build-manifest.json.tmp.0jdcitichqov',
  dest: 'C:\\Users\\jcde0\\dksh-website\\.next\\app-build-manifest.json'
}
 ⨯ [Error: EPERM: operation not permitted, rename 'C:\Users\jcde0\dksh-website\.next\server\middleware-build-manifest.js.tmp.oa55ccccoz' -> 'C:\Users\jcde0\dksh-website\.next\server\middleware-build-manifest.js'] {
  errno: -4048,
  code: 'EPERM',
  syscall: 'rename',
  path: 'C:\\Users\\jcde0\\dksh-website\\.next\\server\\middleware-build-manifest.js.tmp.oa55ccccoz',
  dest: 'C:\\Users\\jcde0\\dksh-website\\.next\\server\\middleware-build-manifest.js'
}

Fonts loaded by next/font/local returns 404 too.

@Tajmirul
Copy link

Tajmirul commented Nov 1, 2023

Same issue here. for now, i just removed --turbo.

@tbenci
Copy link

tbenci commented Nov 9, 2023

Adding --turbo is the main reason we've upgraded. NextJS is a slow old pig and need speeding up. If --turbo is not working why bother.

@enricoros
Copy link

enricoros commented Nov 10, 2023

Same here. I'm using the JetBrains IDE - does it have anything to do with this?
Agree: --turbo is the reason to upgrade to NextJS 14 for me..

@padmaia padmaia added the linear: turbopack Confirmed issue that is tracked by the Turbopack team. label Nov 13, 2023
enricoros added a commit to enricoros/big-AGI that referenced this issue Nov 15, 2023
@ForsakenHarmony
Copy link
Contributor

ForsakenHarmony commented Nov 22, 2023

Is anyone running into this on an OS other than windows?

It's hard for us to reproduce without being on windows

@ForsakenHarmony
Copy link
Contributor

Doing some research, this is a problem with windows specifically.

See: libuv/libuv#1981

Antivirus might be locking the file preventing it from being renamed

So this isn't really a next.js bug, but we can add a retry to work around broken windows behaviour

@peymanath
Copy link
Author

Doing some research, this is a problem with windows specifically.

See: libuv/libuv#1981

Antivirus might be locking the file preventing it from being renamed

So this isn't really a next.js bug, but we can add a retry to work around broken windows behaviour

I will check again

@tbenci
Copy link

tbenci commented Nov 27, 2023

Hi Vercel NextJS team,

This is very frustrating. I installed NextJS onto a bare bones Windows 11 machine with AVG antivirus. That's about it.

I have been working with NextJS for a while without any issues.

When I try to use --turbo, it doesn't work.

Obviously it is working for others but, it is also not working for others.

I am happy to do what every you suggest to try to fix this so tell us what to do.

Just saying it "might be antivirus" doesn't help much. What does that mean and what do we need to do to fix it.

A bit of direction would be most appreciated because all I can tell those that ask me is that --turbo doesn't work.

I tried it on my work machine on a completely different network, IP provider etc. and still it does not work.

Copy link
Contributor

This closed issue has been automatically locked because it had no new activity for 2 weeks. If you are running into a similar issue, please create a new issue with the steps to reproduce. Thank you.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Dec 12, 2023
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. linear: turbopack Confirmed issue that is tracked by the Turbopack team. locked Turbopack Related to Turbopack with Next.js.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

9 participants