Contour Integration $\frac1{\sin z \cos z}$ $\newcommand{\ds}[1]{\displaystyle{#1}}$
I have the contour integral
$$
\oint_{\left\vert\,z\,\right\vert\ =\ 2}\frac{1}{\cos(z)\sin{z}}dz
$$
To make it easier to work with, I use $\ds{\sin(z)=\frac{e^{iz}-e^{-iz}}{2i}}$ and $\ds{\cos(z)=\frac{e^{iz}+e^{-iz}}{2}}$, which when the reciprocal is taken and they are multiplied together I get $\ds{\frac{1}{\sin(z)\cos(z)}= \frac{4i}{e^{2iz}-e^{-2iz}}}$.
I put this back into the integral to get $\ds{4i\int_{-\infty}^{\infty}\frac{1}{e^{2iz}}dz-4i\int_{-\infty}^{\infty}\frac{1}{e^{-2iz}}dz}$.
The second integral can be rewritten as $\ds{-4i\int{e^{2iz}}dz}$, which has no poles so its integral should be $\ds{0}$.
I think with the same logic, I can make the first integral $\ds{4i\int{e^{-2iz}}dz}$, which also has not poles, so the integral is $\ds{0}$ ?.Is this logic valid ?.

If, as I hope, you intend the integral to be
$$
\oint\frac1{\sin(z)\cos(z)}\,\mathrm{d}z
$$
over the clockwise path $|z|=2$, then the integral would be $2\pi i$ times the sum of the residues of $\frac1{\sin(z)\cos(z)}=\frac2{\sin(2z)}$ inside the contour. There are three singularities inside the contour $|z|=2$ at $-\frac\pi2$, $0$, and $\frac\pi2$, with residues $-1$, $1$, and $-1$, respectively. Thus, the integral would be $-2\pi i$.
