The Polaris switch gets its power from the load side of the pool pump switch so that it can only run when the pool pump runs.
I suspect that the main pump motor is beginning to fail from bad windings or a bad capacitor. The capacitor can be replaced if necessary.
I also suspect that the wiring connections might be corroded. With corroded connections, the voltage can drop too much and cause the motor to overheat.
When wiring is not under load, the voltage at the pump will be the same as at the panel.
However, when any load is put on the wiring, the voltage will go down some.
How much the voltage drops depends on the total resistance of the wiring and the load in amps.
With only the pool pump on, the voltage is probably high enough to make the pump run.
When you turn on the Polaris pump, you double the load in amps and double the voltage drop.
Low voltage causes the motor to run at higher amps and overheat.
I suspect that the wire connections slowly corroded over time creating more and more resistance.
I would start by checking amps and voltages. Then check wire connections and switches.
Switches eventually fail. As they age, they can create excessive resistance.