To solve the integral, we will first try to simplify the expression inside the integral.
We know that:
\[
1 - \cos x = 2 \sin^2 \left( \frac{x}{2} \right), \quad 1 - \sin x = 2 \cos^2 \left( \frac{x}{2} \right).
\]
Substitute these into the integral:
\[
\int_{\frac{\pi}{2}}^{\pi} \frac{e^{x} \cdot 2 \cos^2 \left( \frac{x}{2} \right)}{2 \sin^2 \left( \frac{x}{2} \right)} \, dx = \int_{\frac{\pi}{2}}^{\pi} e^{x} \cdot \frac{\cos^2 \left( \frac{x}{2} \right)}{\sin^2 \left( \frac{x}{2} \right)} \, dx.
\]
This simplification can be continued further, but the calculation requires integration by substitution or parts. The final result can be computed using numerical methods or further simplifying the expression for easier integration.