On Wikipedia, one finds a relation between the Weierstrass elliptic function and Jacobi's elliptic functions as
$$ \wp(z; g_2; g_3) = e_3 + \frac{e_1 - e_2}{sn^2 w} $$
where $e_1$, $e_2$, $e_3$ are the roots of the cubic polynomial
$$ 4 \wp^3(z) -g_2 \wp(z) - g_3. $$
The modulus and argument of the Jacobi functions are $$ k = \sqrt{\frac{e_2-e_3}{e_1-e_3}}; \quad w = z \sqrt{e_1 - e_3}. $$
It seems to me that the roots $e_i$ are generally complex-valued. Is that correct? If yes, what branch of the sqrt is one to take for $k$ and $w$? How are Jacobi elliptic functions defined for complex modulus anyway?