ENAMETOOLONG on long slug #32665
Replies: 4 comments 7 replies
-
|
Isn't this a Linux issue? I think in Linux file names can be up to 255 characters in size. What OS are you using locally? |
Beta Was this translation helpful? Give feedback.
-
|
Any update on this? |
Beta Was this translation helpful? Give feedback.
-
|
I am seeing this but with a particular scenario, looks like someone is adding some kind of extra text, like this:
I am not sure if this is some kind of attack of bot crawling, but if you look my url is definitely shorter than 256, the extra text is the problem. |
Beta Was this translation helpful? Give feedback.
-
|
This is still a problem. I think Next.js definitely should validate that the path is not too long before trying write the files. While it probably doesn't cause any harm if you limited the amount of logs, it is still quite annoying. In my case some bot crawlers started trying to crawl paths like: As said above, this only happens in production with ISR enabled dynamic routes. Also it seems like the error happens only once for each path. This is not a Linux specific problem. I think pretty much all operating systems have some sort of limit for the filename or path. There is actually more info about this in Turbopack code. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
I'm facing this issue when slug is too long, any way to fix this other than trimming slug?
What is the maximum limit for slug in this case?
Happening in production only, works fine in dev environment.
Beta Was this translation helpful? Give feedback.
All reactions