Total script/editor failure from 'invalid .info file'

I’m using 2017.2 and recently, while in the middle of working on a project, public variables stopped showing up in the inspector. I refreshed the project and now no scripts were recognised at all. Both old scripts and subsequently created scripts could not be attached to objects ‘until all compiler errors are fixed’. The game also could not be tested ‘until all compiler errors are fixed’, with an empty debug log.
This problem persisted:

  • When I refreshed the project
  • When I reimported all
  • When I deleted every script / left only completely unedited scripts
  • When I canned the whole project, copied the scripts I had before the error into notepad, and pasted them back into a completely new and untouched project

The only lead I have is a startup log saying “Invalid ‘.info’ file discovered, no metadata file.” followed by a list of automatically deleted files. Has anyone seen this before / can anyone help? The problem hasn’t retroactively destroyed my old projects and seems to be tied to the content of the scripts, but I don’t want to risk getting midway through another project only for Unity to arbitrarily decide it doesn’t like a different script.

Nevermind, I found a fix.

I’m having the same problem, can you help with the fix?

For me, it was deleting the “obj” folder that did it, as well as the usual “delete Library folder to reimport everything” fix that works for a large majority of Unity warning weirdness. Another thing you can try that sometimes cleans up weirdness is to delete the Visual Studio .sln and .csproj files, and any “Temp” folder that somehow survives when you exit Unity. Doing all of this deleting should be with Unity closed, of course.

1 Like