GMPY2 est Prime

gmpy2.is_prime(var)
#must have gmpy2 installed and imported
Lucas Gomes