When the battery is connected, the ESC capacitors charge suddenly and cause a spark in the connectors, which can cause a voltage fluctuation at the very moment when the program execution is reading the flight parameters recorded in the EEPROM.
Until you solve the spark problem, you can try this: connect the battery and then disconnect it, wait 3 seconds, connect it again and fly. The second time you turn it on you will no longer hear the spark popping. If the problem is actually caused by the spark, this procedure I hope you may solve your problem.
You appear to know a thing or two about the electronics we use. Does the On/Off switch actually disconnect the ESC internal wiring from the power source and prevent the capacitors from charging? I suspect not but it might prevent the ESC from reading the EECROM. Would connecting the arming plug then waiting to turn on the switch help prevent this from happening? I have been told that I should short out the switch loop and eliminate one source of failure. I am currently building a Twin and was told to just short out ESC 2. From what I am understanding from your post either of these may actually introducing a possible failure to arm that by definition would only happen on an official flight. Am I understanding what you posted?
Ken
In thinking back the only times this has happened to me had the common event of inserting the arming plug with the switch on. Usually because I forgot to bring it on the circle with me then forgot to switch it off while I went back to my box. ( I also forgot my battery stick a lot when I flew IC)
I asked this question of the Bing AI and here is the answer. If it is correct, and we know AI is always correct
then this fully answers why we should use a switch AND an arming plug.
"The Jeti Spin 66 Pro ESC does not load its CCEROM memory when power is applied with the switch off. The CCEROM memory is typically accessed and modified during the programming phase when the ESC is powered on and the switch is engaged. If the switch is off, the ESC remains inactive, and no memory operations occur."
So Saith Jeti
Sometimes I can't help myself. This answer led me to ask if the ESC could be damaged by bypassing the start switch and here is what came back again citing Jeti as the source:
"Applying power to a Jeti Spin 66 ESC with the start switch on can potentially cause damage. The ESC is designed to handle specific power sequences, and bypassing these can lead to issues such as short circuits or overloading the components."