I tested Comp CC in InDesign 2020 and it produced the error attached. There were similar reports in the InDesign and Comp forums.
I got the same error in InDesign CC 2019 (which had worked a few months ago).
This issue has been fixed in our latest release. Please update your InDesign and follow the steps mentioned in below link, for fixing this issue.
Above mentioned steps are required only once. So, that existing files are included inside search index.
For me, the Search field has continued to work in the Open dialog though recent macOS versions. I can't get it to fail.
Thank you for reporting the issue to us,
We are looking into it and shall update here, soon.
Fix is available in version 13.1 of InDesign.
Please update to the latest version available to you via Creative Cloud Desktop application.
Adobe InDesign team
Yes, I also experience this in OS X 10.13.