Search Issue Tracker
By Design
Votes
0
Found in
2018.3.0a6
2018.4.9f1
2019.2.0a1
2019.3.0a1
2020.1.0a1
Issue ID
1187120
Regression
Yes
Building in batchmode after deleting a file completes the build successfully, but logs an error about the missing file
How to reproduce:
1. Open user-submitted project (Empty_Project_removefile)
2. Build the project
3. Close the project and delete the ClassToBeRemoved.cs and its meta file from Assets/TestAsm folder
4. Build the project in batchmode with the following arguments: -batchmode -quit -executeMethod BuildScript.BuildFromCommandLine
5. Once the build completes successfully check the Editor.log
Expected result: no errors are logged
Actual result: error CS2001: Source file `Assets/TestAsm/ClassToBeRemoved.cs' could not be found is logged
Reproducible with: 2018.3.0a6, 2018.4.10f1, 2019.2.8f1, 2019.3.0b5, 2020.1.0a7
Not reproducible with: 2017.4.32f1, 2018.3.0a5
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
- "Shader warning in 'Hidden/Light2D': implicit truncation of vector type" is thrown when building Universal 2D template
- AI Assistant breaks compilation of packages using System.Runtime.CompilerServices.Unsafe via auto-referencing
- Unity Hub checks the "Documentation" module by default on the 6.4 and 6.5 streams despite that it was unchecked with the previous installs
- Shortcut that toggles between Dopesheet and Curves Views in the Animation Window's Timeline is mislabed
- Property List Items Overlap onto the Property List's top edge when scrolling through a long Property List
Resolution Note:
The only part that fails is the initial compile attempt. Later in the log, but before it calls into the user code, the asset database refreshes the assets and detects the deleted file, triggers a recompile which does succeed. Then continues on to build successfully. The log shows the recompile with the following lines:
Refresh: trashing asset cf3ece5c714b9b943a973f5cd27039e5
- Starting compile Library/ScriptAssemblies/TestAsm.dll
- Finished compile Library/ScriptAssemblies/TestAsm.dll