Solution (source code)

= Solution

On the square, $|z|\geq N$. The identity $|\sin\pi(x+\alpha+iy)|^2=\sin^2\pi(x+\alpha)+\sinh^2\pi y$ bounds the sine away from zero on the vertical sides because $x=\pm N$; on horizontal sides it grows exponentially. Therefore the whole <contour integral> is $O(N^{-1})$ or smaller and vanishes. The <residue theorem> then gives
$$
0=2\pi i\left[-\pi\csc\pi\alpha\cot\pi\alpha+\sum_{n\in\mathbb Z}\frac{(-1)^n}{\pi(n-\alpha)^2}\right],
$$
which proves $\boxed{\sum_{n\in\mathbb Z}(-1)^n/(n-\alpha)^2=\pi^2\csc\pi\alpha\cot\pi\alpha}$. <Absolute convergence> justifies the limiting <residue> sum.