What are the long term complications of a baby having open heart surgery for an asd?

Minimal. Open heart surgical repair of an ASD carries the most risk at the time of surgery, due to anesthesia. Long term a few patients will develop an atrial arrhythmia; most are perfectly fine.
Unlikely. Since an ASD involves low pressure chambers closing the hole, if it is done before damage to the lung vasculature will solve the problem. Unlikely surgery may damage part of the heart's electrical system. This is more common one type of asd.
Many but... There are many long term issues, but most have become relatively minimal, especially with asds. We know that there's an association that all children who undergo cardiac bypass have slightly lower iq scores. But we do not know if this is because of the operation or the heart diseases themselves. The risks of bypass and surgery and far less than leaving the ASD alone or we wouldn't operate.