-
Bug
-
Resolution: Fixed
-
1.19.4 Pre-release 1, 23w14a
-
None
-
Community Consensus
-
Commands, Save Data
-
Normal
-
Platform
Issue/Expected result:{}
If you attempt to data modify from a string, but your end exceeds the length of the string, the command returns "unexpected error".
The expected result in my opinion is that since the command failed, we get a success of 0, however, as you will see, success erroneously returns 1
Steps to reproduce:
#simple setup for the following code to work /summon marker ~ ~ ~ {Tags:["example"]} /scoreboard objectives add test dummy /scoreboard objectives setdisplay sidebar test
#Correctly success=1, marker->data.message has 'over'
/execute store success score @p test run data modify entity @e[type=marker,tag=example,limit=1] data.result set string entity @p SpawnDimension 10 14
#Marker data does not update, however, success is still true
/execute store success score @p test run data modify entity @e[type=marker,tag=example,limit=1] data.result set string entity @p SpawnDimension 10 100