I came across this issue recently too when using Unity 2022.3.0.
I believe the faulty piece is the Unity component SortingGroup within the [BB] Hand Ray prefab. I inspected the Unity changelong and it looks like this bug could cause it:
I updated my project to the latest Unity 2022.3.46f and could successfully build.
Please let me know which version were you using and if this fixes your problem!
Did you change the Prefab in any way (apply Prefab modification, enter Prefab mode and made changes, etc.?)
– MirceaI