It's a royal pain. After several attempts with shredded wires a friend of mine put the wires on the side of the gearbox in the small "gulch" and filled it up with some sort of putty. That finally did the trick as the wires (4 after installing a mosfet) stayed put at last.