Search Issue Tracker
Won't Fix
Votes
6
Found in
2020.3.42f1
2021.3.15f1
2022.1.23f1
2022.2.0f1
2023.1.0a23
2023.2.0a1
Issue ID
UUM-21078
Regression
No
"DirectoryNotFoundException: Could not find a part of the path" thrown when creating a new C# Script in a path longer than 260 characters
How to reproduce:
# Create a new Unity project
# Create a path longer than 260 characters in the Assets folder
# Create a new C# Script in that folder
Expected results: The C# Script is created
Actual results: "DirectoryNotFoundException: Could not find a part of the path" thrown in the Console window
Reproducible with: 2020.3.42f1, 2021.3.15f1, 2022.1.23f1, 2022.2.0f1, 2023.1.0a23
Reproducible on: Windows 10
Add comment
All about bugs
View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.
Latest issues
- "Objects are trying to be loaded during a domain backup." errors on entering Playmode
- Transform Node does not have outputs when it is created
- Changing the Default Icon does not change the executable's icon when re-building the project
- Texture is stored upside down when using Blit
- [OpenGLES][XR] Zooming in on the camera's URP opaque texture causes "double vision" on Quest in OpenGLES3
Resolution Note:
Unfortunately, we won't be able to fix this issue: Even if we manage to find all potentially problematic usage of CreateFile APIs in our own codebase, Unity Editor actually communicates with many tools we don't have control of (e.g. platform-specific compilers etc.). So we will never be able to fully support long paths on Windows.