- Home /
Unity stuck on "Importing" while starting Unity 2020
When I start Unity 2020 from Unity Hub it gets stuck on either "Importing" or "Compiling Assembly Definition Files scripts". So I can't get into any Unity project.
I am running 2021.1 and having a very similar issue. I don't know if it's because I'm using a very new version, or if it's caused by a bug in a package I'm using.
I tried deleting the Libraries folder like @sarahnorthway suggested (this was about a month ago). And I think it fixed the issue at the time. But now it's happening again.
The only silver lining is that if I force quit the process in Task Manager, and relaunch the project. It opens totally fine. And each time I shutdown my PC, and then turn it back on the next day, I have to go through the same annoying stupid process of forcequitting the project. More time wasted doing shi-- I mean-- stuff like this. Which makes working in Unity feel even more tedious and unstable. It's like walking through a $$anonymous$$efield. anyway!
I might try deleting the Library folder again. But I wanted to bump this thread, because I feel like a official Unity Dev might have some insight into this.
Answer by sarahnorthway · May 20, 2021 at 04:40 AM
Try deleting (or moving to your Desktop) the Library folder in the root of your project. It contains Unity's cache which might be corrupted. Next time you open the project it should take a much longer time than usual to reimport everything.
Answer by Jorhoto · Oct 14, 2021 at 05:53 AM
Same issue here, if I exit Unity via taskbar and relaunch it works back, but, as soon as PC is restarted the issue may reappear.
[Solved] Auro-response: I found that, the PC experiencing this issue, had a malwhare and, after removing it, everything started to work as usual. So, take a look at your running processes and services and an antivirus scan should help as well.
Answer by ryanmillerca · Oct 14, 2021 at 03:02 PM
A corrupted asset can cause this. If deleting Library and opening the project again doesn't help, then check the Editor logs. Do this after closing/crashing the application and you may be able to find what it's getting tripped up on. See here: https://docs.unity3d.com/Manual/LogFiles.html under the Editor header to find out where those are on your machine. There have been problems importing various file types in certain software configurations / unity versions / operating systems over the years.
Answer by mattrdell · Oct 03, 2021 at 02:37 PM
Ooof, don't delete you meta files. Your library is probably corrupt, delete the Library folder, it will regenerate the database from the metafiles.
Answer by gnostici · Jan 03, 2021 at 05:58 PM
This question appears in three places online, and the only answer it has anywhere is, "That's a serious problem," on Reddit. Amazing.
This worked for me:
Delete every .meta file in your assets folder.
Delete every project (Visual Studio or Jetbrains Rider) file in your root project folder.
Restart your machine and try again.
This forces it to regenerate everything, so you'll still have to wait for it to import. But you'll notice in Task Manager that CPU usage is no longer 0%, and the editor will launch in the end.
Unity uses .meta files to connect assets together, so (unless I'm mistaken and Unity keeps a backup?) removing them may remove assets from your scenes as well. Bad times!
For Rider you can select File > Invalidate Caches to force a refresh of all the scripts without losing your project preferences.
What you probably want to delete is the Library folder, which will force Unity to completely rebuild its cache.
If you don't know the answer just don't give the bad advice. Deleting meta files will destroy the project, becuase unity keep asset internal ids into them. It means that all references in prefabs and gameobjects will be lost.