Project with spaces in directory name started failing

It appears that since today a build (with no recent significant changes) started failing. The logs indicate that it is caused by spaces in project name. The failing action seems an external command in cleanup phase. I would guess that the directory should be enclosed in quotes when invoking the external command (the ls command tries to process all words in project directory name separately).

Is this happening to anyone else or just me? If this is a bug introduced by a recent update, is it expected to be fixed soon, or should I start looking into renaming the directories in git?

Thanks!

This is the failure in full build log:

1069: [Unity] Cleanup mono
1070: [Unity] Unloading native extension module for target: iOS
1071: [Unity] Exiting batchmode successfully now!
1072: Cleaning up
1073: ls: Exclusion: No such file or directory
1074: ls: Spot: No such file or directory
1075: + Building exported player (iOS)
1076: find: /BUILD_PATH/pet-spot.551b97ea64b2ee6d550cec02.default-ios/Pet
1077: Spot
1078: Exclusion: No such file or directory

For comparison, this is the same log passage from yesterday, which succeeded.

1049: [Unity] Cleanup mono
1050: [Unity] Unloading native extension module for target: iOS
1051: [Unity] Exiting batchmode successfully now!
1052: Saving Library to cache
1053: Cleaning up
1054: + Building exported player (iOS)
1055: Detected Framework: /BUILD_PATH/BVR_TEMP_DIR/d20150408-2043-ppe7s8/Pet Spot Exclusion proto

We fixed the problem and rolled out a patch. Would you please try it again now and let us know if it works properly again? :slight_smile:

1 Like

Now building the project works again! Thanks for the quick response!

1 Like

Still encountering the same issue today in 2021, tried with Unity Hub 3.0.0-beta.4 and various unity versions (2020.3.17f1, 2019.4.22f1)

I had this issue today with Unity 2021.3.16f1. Simply renaming the folder and reimporting the project into unity hub seems to have fixed it.

1 Like

Honestly, if you’re going to develop software, you should just develop the discipline. Anything and everything related to compiling code should just avoid spaces and oddball characters in filenames. Just as C# variable names cannot have spaces or brackets or periods in them, filenames should also avoid any characters which may confuse the tools that access them.

It’s definitely possible for the people on the Unity (and Blender and Linux and Android and iOS and…) teams to play whack-a-mole and find every possible condition that has an issue with spaces in filenames, and fix those issues, but it’s much more straightforward to learn the data hygiene skills to avoid the likelihood of getting caught out by this.