-
Bug
-
Resolution: Works As Intended
-
None
-
1.18.1
-
None
-
Confirmed
-
(Unassigned)
Using /tag to add an identical tag to an entity causes the command to fail (because entities cannot have two of the same tag). However, attempting to do the same thing using the /data modify command returns a success even though the identical tag is never added.
How to replicate:
Create a dummy scoreboard objective and a dummy entity with arbitrary tags
scoreboard objectives add test dummy
summon armor_stand ~ ~ ~ {Tags:["dummy"]}
Try to add a duplicate tag to the dummy entity using{{ /tag}} and store success in dummy scoreboard
execute store success score @s test run tag @e[tag=dummy] add dummy
Now, try to add a duplicate tag to the dummy entity using /data modify and store success in dummy scoreboard
execute store success score @s test run data modify entity @e[tag=dummy,limit=1] append value dummy
In the first attempt, the player's test score is 0 because the command failed, but in the second attempt the player's test score is 1 because the command "succeeded" despite the duplicate tag not being added (this can be confirmed with the /data get command).