I have a possible workaround--though I've only tried it once, just now, today. Get a save right before your surveyor is about to explore the evil pirate ambush, stop the auto-survey, and order the ship there manually. I got a 'are you sure, there's pirate there' popup, and I said yes. And the ship went, there, and combat happened like its supposed to (my ship lived). Ever since then, though--on this particular savegame, at least, the surveyor can auto-explore onto pirates, and combat has worked fine ever since then.
So my workaround would be to order the ship to the first ambush manually, and it should be able to auto-survey into later ones with no problem. Not sure if this will work for all, though--as this bug appears to be a bit weird and sporadic--or if I just got lucky. Also, at this point in this game, I only have one surveyor. Not sure if you'd need to do it manually once for each surveyor or not. But hope it helps.