mojira.dev
MC-276906

Specifying a block tag in an item's can_place_on or can_break component in a recipe or loot table causes validation error

Referencing a block tag in a recipe or a loot table in an item's can_place_on or can_break component causes the datapack not to load.

How to reproduce:

  1. Download the attached datapack and try to load it in a world

  2. Notice the datapack doesn't validate

  3. (optional) Remove the block tag references from the loot table and recipe and reload; notice the datapack loads

Attachments

Comments 3

Thank you for your report!
After consideration, the issue is being closed as Invalid.

You have posted a feature request or a suggestion. This site is for bug reports only.
For suggestions, please visit The official Minecraft feedback site or visit the Minecraft Feedback Discord server.

Quick Links:
📓 Bug Tracker Guidelines – 💬 Community Support – 📧 Mojang Support (Technical Issues) – 📧 Microsoft Support (Account Issues)
📓 Project Summary – ✍️ Feedback and Suggestions – 📖 Game Wiki

This is a regression from 1.21.1 where these loot tables and recipes worked fine.

It should also be noted that using block tags in these components works fine when used in a /give command or inline loot tables.

Please reopen.

This is a highly important issue to fix, and most definitely can be considered a bug.
If implemented in 1.21.2, existing datapacks will break in ways that are nearly impossible to smoothly fix.

Why is this considered invalid?
Please reconsider if possible, thanks 🙂

fedpol1

(Unassigned)

Confirmed

Platform

Important

Data Packs

24w38a

1.21.2 Pre-Release 2

Retrieved