The function in question is $f(x)= \frac{\pi}{\sin\pi\alpha}e^{i(\pi-x)\alpha}$ where $\alpha$ is not an integer.
With a bit of elbow grease, one can find that the Fourier series for $f$ is $\sum_{n=-\infty}^{\infty} \frac{e^{inx}}{n+\alpha}$, so we apply Parseval's and try to work out $||f||^2$ to get the identity.
So $$||f||^2 = \frac{1}{2\pi}\int_{0}^{2\pi}\frac{\pi^2}{\sin^2\pi\alpha}e^{2i(\pi-x)\alpha} dx$$ And some more elbow grease, I got to $$||f||^2=\frac{\pi^2 \sin2\pi\alpha}{2\pi\alpha\sin^2\pi\alpha}$$ Which seems really close as there seems to be something close to a squeeze theorem going on, but alas there are no limits to make the excess junk go away. How can I simplify further to get the desired $||f||^2=\frac{\pi^2}{sin^2\pi\alpha}$? Or perhaps I missed something along the way?
You just need to take the square modulus of $f$, not the square. Indeed,
\begin{equation} \vert f(x)\vert^2=\frac{\pi^2}{(\sin \pi\alpha)^2} \vert e^{i(\pi-x)\alpha}\vert^2=\frac{\pi^2}{(\sin \pi\alpha)^2}, \end{equation}
so integrating with the correct normalization gives the desired formula for $\|f\|^2$.