Purrgils first appeared in “Star Wars Rebels.” Hera Syndulla, the captain of The Ghost, explained to Ezra Bridger that most spacers found them to be pests because they cause crashes in hyperspace. Ezra, though, found himself connecting to the creatures through the Force.
In the finale of “Star Wars Rebels”, when Grand Admiral Thrawn had the entirety of Phoenix Squadron backed into a corner on Lothal and demanded their surrender, Ezra sacrificed himself to go aboard Thrawn’s ship, The Chimaera. That’s when he brought the purrgils to the fight. They appeared from hyperspace at his call, surrounding Thrawn’s Star Destroyer and the others in his fleet, holding them all in their grip, and jettisoning into parts unknown, taking Ezra and Thrawn with them.
It effectively ends the conflict on Lothal, liberating it for the Rebel Alliance. To this point in the timeline, Ezra doesn’t get to see his home planet liberated, though, because he’s off in parts unknown with Thrawn. Did they survive the flight of the purrgils? Ahsoka Tano sure seems to think so.