How can we prove this identity? Which, btw, Mathematica know how to simplify so it is missing some fundamental identity (related to the lemniscate constant.)
\begin{equation} s = 2 \int_{- \pi}^{\pi} \left| \frac{\sin (t) - i}{(\sin (t) + i)^2} \right| dt = 2 K (- 1) = 2.62206... \end{equation} where $K$ is the real quarter period function? K is also called a complete elliptic integral of the first kind.
The parametric equations for the lemniscate of Bernoulli with parameter 2 are given by \begin{equation} \begin{array}{ll} y (t)=\frac{2 \cos (t)}{\sin ^2(t)+1} and { } x(t)=\frac{2 \sin (t) \cos (t)}{\sin ^2(t)+1} \end{array} \end{equation} where $\int_0^{\frac{\pi }{2}} \sqrt{x'(t)^2+y'(t)^2} \, dt=2K(-1)$
Let us combine the coordinate functions $(x (t), y (t)) \in \mathbb{R}^2$ into an equivalent function $z (t) \in \bar{\mathbb{C}}$ \begin{equation} \begin{array}{ll} z (t) & = x (t) + i y (t)\\ & = \frac{{2} \cos (t)}{1 - i \sin (t)} \end{array} \end{equation}
then the integrand is the absolute value of the derivative of z(t)
It's just weird that mathematica was not able to factorize the absolute value of z'[t] back into its components Re[z'[t]]=x'[t] and Im[z'[t]]=y'[t]
You mixed up some factors of $2$ in your question. The correct equation is $$\frac{1}{4}\int_{-\pi}^\pi \left|\frac{\sin t-i}{(\sin t+i)^2}\right|\mathrm dt= \operatorname{Eli}_1(-1)$$ Where $$\operatorname{Eli}_1(z)=\int_{0}^{\pi/2}\frac{1}{\sqrt{1- z\sin^2 t}}$$ Numeric verification:
(I prefer to use $\operatorname{Eli}$ instead of $K$ in order to avoid confusion with the modified Bessel Function of the second kind. )
All you need to do is check that $$\left|\frac{\sin t-i}{(\sin t+i)^2}\right|=\frac{1}{\sqrt{1+\sin ^2 t}}$$ This is certainly tedious, but not difficult. Then, $$\int_{-\pi}^\pi \frac{1}{\sqrt{1+\sin ^2 t}}\mathrm dt=4\int_{0}^{\pi /2}\frac{1}{\sqrt{1+\sin ^2 t}}\mathrm dt\equiv 4\operatorname{Eli}_1(-1).$$