Searching by Finder Tags not working in Spotlight on macOS High Sierra

I started using Finder Tags very extensively a while ago. However, I noticed this strange bug (at least on my macOS High Sierra): Searching for tags by writing

tag:<name_of_tag>

is not working for me in Spotlight.

I can successfully write <name_of_tag> into Finder search window, and it will both recognize it as tag and show me the relevant files. Therefore, it looks like a bug specific to Spotlight, as searching for tags is supposed to work system-wide.

Is there any workaround or fix for this issue?


After searching the internet a little bit, I found a recent post in Apple Discussions explaining the reason for bug. In non-english versions of macOS (at least German and Slovak), searching by

tag:<name_of_tag>

query does not work. Replacing the tag keyword by kMDItemUserTags fixes the problem and properly shows relevant files even from Spotlight:

kMDItemUserTags:<name_of_tag>