...used the wormhole generator to remove the Xeloxi fortresses and survey the anomaly.
That is interesting. I tried that in past and removed the ships without a problem. When I tried to survey the anomaly, a whole new fleet of the pirate fortresses was guarding it. Things were worse than before. I may have waited a turn before I could get a survey ship there, which may have allowed the defending ships to reappear.