We are in the process of updating our legacy Spotlight MDImporter to the new macOS Spotlight App Extension.
The transition works well for standard attributes such as title, textContent, and keywords.
However, we encounter an issue when adding custom attributes to the CSSearchableItemAttributeSet.
These custom attributes are not being persisted, which means they cannot be queried using a Spotlight NSMetadataQuery.
Has anyone an idea on how to append custom attributes so that they are included in the indexed file status, as displayed by the shell command mdimport -t -d3 <path>
A sample project illustrating the problem is available here: https://www.dropbox.com/scl/fi/t8qg51cr1rpwouxdl900b/2024-09-04-Spotlight-extAttr.zip?rlkey=lg6n9060snw7mrz6jsxfdlnfa&dl=1