Search Unity

Bug Random hangs while building, importing shaders, and more

Discussion in 'Editor & General Support' started by chemicalcrux, Nov 30, 2022.

  1. chemicalcrux

    chemicalcrux

    Joined:
    Mar 16, 2017
    Posts:
    720
    I've been having issues with Unity randomly deciding to hang while the "loading" dialog is visible.

    This is in 2021.3.9f1, but I've been having problems in multiple versions. I'm on an M1 Macbook, using the Silicon builds of the editor. It never happens when reloading scripts. It often hangs while the dialog says it's importing a shader. It will also often hang during builds (I think it says something about switching build platforms?)

    I've tried attaching a debugger, and it smells like a deadlock to me: all of the worker threads are waiting to get work from a queue, but nothing is actually happening.

    Deleting the Library folder doesn't fix this, since I've had it freeze during the following import!

    The editor never crashes, so it's not like I'm getting crash dumps; I just have to force-quit it and reload. That means I can't submit useful bug reports. What can I do to help nail this issue down?