Search Issue Tracker
Fixed in 2022.2.X
Fixed in 2021.2.X, 2022.1.X
Votes
0
Found in
2021.2.0a21
2021.2.4f1
2022.1
2022.2
Issue ID
1396974
Regression
Yes
"Couldn't open include file" error is thrown when compiling a Shader and Unity Accelerator is being used
How to reproduce:
1. In Unity Hub, add the user-submitted project
2. Under "Editor Version", click the three dots button and select "Add command line arguments"
3. In the "Add command line arguments here" textbox, add the argument "-disableShaderCacheRemote" and click "Save"
4. Launch the project
5. Open the Preferences window and set the Unity Accelerator default Mode to "Enabled" (Unity > Preferences... > Asset Pipeline > Default Mode)
6. Install Unity Accelerator (https://docs.unity3d.com/Manual/UnityAccelerator.html#installer)
7. In the last step of the installation process, copy the displayed Host IP address
8. In the Unity Editor Preferences window, paste the IP into the "Default IP address" field
9. In the project window, select the Asset "NewComputeShader" (Assets/NewComputeShader.compute)
10. In the Inspector window, select "Show compiled code"
11. Close the Unity Editor and in the OS File Browser, navigate to the project location
12. Rename the project folder and delete the Library folder inside
13. In Unity Hub, add the newly renamed project, add the "-disableShaderCacheRemote" command line argument and launch the project
14. In the project window, select the Asset "NewComputeShader" (Assets/NewComputeShader.compute)
15. In the Inspector window, select "Show compiled code"
16. Inspect the Console window (Window > General > Console)
Expected result: No errors are seen in the Console
Actual result: "Shader error in 'NewComputeShader'" error is seen in the Console
Reproducible with: 2021.2.0a21, 2021.2.9f1, 2022.1.0b5, 2022.2.0a2
Not reproducible with: 2019.4.35f1, 2020.3.27f1, 2021.2.0a20
Full error:
Shader error in 'NewComputeShader': Couldn't open include file 'Test.cginc'. at kernel CSMain at NewComputeShader.compute(15)
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
- Articulation Body with 'Revolute' Joint Type has erratic behavior when Upper Limit is set to above 360
- WebGL Player fails to render Scene when Terrain with Detail Mesh is added and WebGPU Graphics API is used
- Inconsistent errors are logged when different types are passed into the Query "Q<>" method in UIToolkit and the ancestor VisualElement is null
- Crash on GetMaterialPropertyByIndex when opening a specific Scene
- Discrepancies in the styling are present when using a TSS file instead of a USS file in custom EditorWindow
Resolution Note (fix version 2022.2):
Fixed in: 2022.2.0a4
Resolution Note (fix version 2021.2):
Fixed in: 2021.2.14f1