The chief prosecutor for Boston said Thursday he will not pursue a criminal contempt complaint against a U.S. Immigration and Customs Enforcement agent who took a defendant into custody in the middle of a trial last month, calling a state court judge’s finding and referral “patently illegal.”