The /enchant
command can be used to enchant items with a level of 0, when it should only succeed at a level of 1 or more.
Steps to Reproduce:
Hold an un-enchanted tool in your main-hand
Run the following command:
/enchant @p minecraft:unbreaking 0
Expected Result:
The command would fail — showing a command in chat, and do nothing to the item.
Observed Result:
The command acts as though it succeeded, sending a message in chat. Nothing will happen to the item, and it will remain un-enchanted.
Linked issues
is duplicated by 2
relates to 2
Attachments
Comments 22
In 1.20.6 this still acts like it is successful, but the item no longer has the enchant glint or desc. So it is partially fixed.
Can confirm in 1.21 Pre-Release 4, however, the item does not get enchanted.
The command still gives a success message.
The error message when enchanting with an invalid value even says, "Integer must not be less than 0" so if even that explanation is coded that way, could it be (for some useless reason) intended?