I had a relay in the main box by the battery flake out years ago. It would either make the engine hesitate at times or stall suddenly. Sometimes it would restart right away and sometimes not. The relay ran the ignition and fuel pump systems.