Unity Editor Hangs after compiling

Hi,

I recently went through the process of running some updates (VS Code Editor package, Unity Hub, maybe 1 other) and ever since, the editor hangs for ~20-40 seconds after it completes a recompile. After I save an updated file, the little circle will spin, and then the editor will quit responding for several seconds, and then will work fine until it re-compiles again. When this happens, Windows task manager registers the editor item (in attached photo) as not-responding, and the resource usage jumps up pretty drastically (up to ~19% CPU and 800MB memory)


Things I’ve tried:

  • Testing a different project - problem does not happen there
  • Re-importing all assets - doesn’t help
  • Closing asset store and logging out of account - doesn’t help
  • Allowing Unity through Windows Defender - didn’t help

Note: Running v2019.2.10f1 on a Windows machine.

Any recommendations?

I think I figured it out. TLDR at the bottom.

First, I deleted all project files with the exception of “Project Settings” and “Assets”. Opened the editor, no dice.
Next, I exported my assets folder as a package and imported it into a new project. Initially, the hanging error did not follow.
Next, I popped open the Packages window and started importing packages I needed, first Probuilder, and next ProGrids. This is when I noticed a problem. As soon as I selected the “Show Preview Packages” option, the editor started to hang. At this point, I switched back over to the main project where I discovered this issue and tried deselecting “Show Preview Packages” and closing the Package window. Viola!

TLDR: Deselecting “Show Preview Packages” and closing the package window (I had it as a permanent tab) helped.

1 Like

Great find, thank you so much! :slight_smile:

Edit: It does not seem to matter if the window is open or not: Mine was closed. But switching “Show Preview Packages” helped.