Search Index much larger than sum of entire contents

I have a search index that keeps crashing my Unity.
It’s over 118 prefabs, but somehow it balloons to nearly 21000 elements.
Same is kind of true to my Assets index, which usually doesn’t hang when reindexing, but is insanely slow.

What can I do to make these things remotely useful and less of a workflow disruption?

It isn’t even that big a project - 3.1 GiB Assets folder. Most of it textures.

Usability feedback:

Clicking “Cancel” on the Directory Search dialog when clicking “Choose Folder” will, instead of Cancelling, CLEAR the Folder field. No Undo. Better remember what that folder was. And better not click on one by accident.

Hi! The number of elements shown is the number of entry in the index. Each documents indexed can add lots of entries, depending on the options selected. Try playing with the options to see how it changes.

However, the index takes only 1.9MB so it shouldn’t take long to index and should hang Unity. We will have to investigate. What version of Unity are you using?

Thanks for the feedback. That is a bug. Can you report it so it is easier to track? Thank you!

Unity 2022.3.5f1 at the time of reporting.

How do I report a bug like that, do I need to package a sample project?

Hi @Thygrrr ,

Sorry for the delay. I just got back from vacation and Sebastien Grenier is on vacation himself.

Some information:

  • The number of “indexed values/properties” is different than the number of indexed files. Dependning on your indexing option, you could potentially indexed a LOT of properties from an object. We index type information, all serializedProperties and a lot more.

About the crash:

  • I noticed that when indexing material, some MaterialEditor can make the editor crash. This has been fixed in most version though (we have unit tests to trigger crash during indexing and indexing can end correctly). Can you test with the latest 22.3?

About slow indexing:

  • Indexing is done in a background process (it is in fact done during the Asset Importer pass by the assetImporter process). Usually indexing time grows depending on how much data you want to index.

The default indexing options are PRoperties and types:
9241809--1291668--upload_2023-8-22_12-59-38.png

Adding Dependencies and especially SubObjects can increase indexing time. Sub Objects will actually open all scenes and prefabs and indexed their content. What are the options you are using?

If you have a way to either create a repro project (for the crash especially) and attach it to the bug using the bug reporter that would be awesome.

9241809--1291671--upload_2023-8-22_13-1-11.png

Thanks for the patience.

Seb

Hi @Thygrrr I notiuce you have logged a bug IN-49756. Can the project attached to this bug (juniper-blue) be used to test the issue you talked above?

Uhhh, that project reproducibly crashes on my AMD machine on first and subsequent import.
It doesn’t seem to have working indexes to reproduce the problem of “large” indexing times.

In 2022.3.7f1, the issue has improved; I still see it a lot but it seldom hangs on indexing. I’ll look into a reliable reproduction.