Search Issue Tracker
By Design
Votes
1
Found in
2022.2.9f1
2023.1.0b4
2023.2.0a4
Issue ID
UUM-28768
Regression
Yes
The "Invalid subscript 'positionOS'" error appears when using the URP package shader libraries
Steps to reproduce:
1. Open the attached project “ShaderError“
2. Select the “Assets/LightShaft/Shaders/LightShaft.shader“ shader
3. In the Inspector window observe the Errors list
Expected result: No errors are displayed
Actual result: The “invalid subscript ‘positionOS'“ error is displayed
Reproducible with: 2022.2.0a16, 2022.2.9f1, 2023.1.0b4, 2023.2.0a4
Not reproducible with: 2020.3.43f1, 2021.3.16f1, 2022.1.24f1, 2022.2.0a15
Reproducible on: Windows 10
Note: Recompile the Shader if the “Couldn’t open include file“ error is displayed
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
- Disabled assets in Import Unity Package window aren't tracked but count as being selected by user
- [Windows] Crash on GetManagerFromContext when video is playing and creating High Definition 3D Projects after FMOD failed to switch back to normal output Error appeared
- GC Alloc produced when adding items to MultiColumnListView with Auto Assign Binding
- Mouse and Pointer Events are called incorrectly in ScrollView with XRUIInputModule
- Memory leak occurs when repeatedly minimizing and maximizing the UI Builder window
Resolution Note:
The LightShaft.shader depended on some internal shader files from URP that changed. The shader needs to be updated to appropriately declare the the shader vertex description.
It's also recommended to check the upgrade guide here: https://docs.unity3d.com/Packages/com.unity.render-pipelines.universal@16.0/manual/upgrade-guide-2023-1.html#the-universal-renderer-is-now-using-the-rthandle-system