Problem
Suddenly, my builds are failing for my project. There are only four build log lines. There’s the build location, machine, repo + commit, and the error:
Error: Unable to unpack repo: there was at least one filename that was too long
Context
Unfortunately, this repo is not public, so I can’t directly link this exact repro. However, the longest filename in the repo from the repo root is 181 characters long. This figure did not change between the last working build and the first failing build.
- Framework:
Next.js 16.1.1-canary.11 - Environment: Monorepo, "Include files outside the root directory in the Build Step" enabled.
- Build Machine:
Standard.
A few days ago, I started getting Unable to unpack repo: there was at least one filename that was too long build failures on my project. No deployment since then has succeeded; all builds fail with this reason. The commit that first resulted in this failure did not add a file with a long name, making me wonder if this was a configuration/build env change.
Questions
There is no additional information beyond the four build log lines. So it would be nice if I could figure out the following:
- Which file (or files) is over the limit?
- What the limit is?
- Whether the limit is relative to the repo root or the build machine’s root?
In terms of my configuration on Vercel, it seems like the build is failing before my build command is executed, so that must not be the problem.
I’m deploying an app that is a package in a monorepo. I do have "Include files outside the root directory in the Build Step" on because there is a file from another package I’m depending on.
Ultimately, additional visibility into the error would be much appreciated! In lieu of that, I will have to start making guesses about what to change to get my builds to succeed again. Or, as Claude recommends, move to GitHub actions for deployment.