It's not posible to specify block type in the query.is_item_name_any query, that means that you can not use it to check for certain type block like "acacia planks", instead it's limited to
query.is_item_name_any('<slot>', 'minecraft:planks'), and that's only able to look for the oak planks.
Actually it's not a bug, just something unfinished, but it's more important than a simple suggestion (since all who use the Mojang language will probably need it at some point).
What I expected to happen:
It would be fine that you could specify block type by using the typical syntax, that's this way: query.is_item_name_any('<slot>', 'minecraft:planks:4'). This query would be expected to check for acacia planks.
What actually happened:
There is no way to use the menthioned query (query.is_item_name_any) to check for certain block type.
Steps to Reproduce:
Use the query like it's suggested, inside a resource or behavior pack, it just won't work if it looks for certain block type.
Comments 4
This issue is being temporarily resolved as Awaiting Response. Once the requested information has been delivered, the report will be reopened automatically.
Quick Links:
📓 Bug Tracker Guidelines – 💬 Community Support – 📧 Mojang Support (Technical Issues) – 📧 Microsoft Support (Account Issues)
📓 Project Summary – ✍️ Feedback and Suggestions – 📖 Game Wiki
To add additional context, at one point it was mentioned that some blocks with such block states would be broken out into their own identifiers (or aliases), but even so this still would have to be fixed due to the way some items, such as water bottles (being the default state 0 for a minecraft:potion item) when queried, would return true for any potion - there's no way to determine that the player is specifically holding a water bottle and not a mundane potion, for example.