Mojira Archive
MC-121589

No error message when loot table does not exist

The bug

In previous version there used to be an error message when a loot table did not exist. In the latest versions this is no longer the case.

This affects all kinds of loot tables usages, including:

  • /loot
  • block loot tables
  • entity loot tables

How to reproduce

  1. Use the following command
    /setblock ~ ~ ~ chest{LootTable:"invalid"} replace
    
  2. Open the chest
  3. Look at the log
    No error was logged

Code analysis

For 20w07a with Mojang names

net.minecraft.world.level.storage.loot.LootTables.get(ResourceLocation) simply returns an empty loot table if the loot table is not found.