The big difference is that with the robot, the hit team has already left the country.
So most likely left there the night before (or even longer), they knew when he would be by (and it wasn’t going to be a one-off), and there you go.
The US Secret Service has had several folks who aren’t worried about consequences sneak through and severely injure - or depending on your pet theory regarding JFK - kill presidents.