1. Be in adventure/survival mode and summon a Skeleton; notice that it shoots you correctly.
2. Use a repeating command block to do {{execute as @e[type=skeleton] run data merge entity @s {CustomName:" "}}}
3. It no longer shoots correctly.
This works with merging data of any sort (to my testing so far) other than merging no data (i.e. {})
See MC-66943: