Consider the integral $$\frac{\int_{b-i \infty }^{b+i \infty } \frac{\exp (a z)}{\sin (\pi z)} \, dz}{2 \pi i}$$ where 0 < b <1 and |Im a| < 1. Below is Mathematica code which evaluates this integral 1) directtly and 2) evaluating the indefinite integral between the two limits. The Mathematica command:
value1=Assuming[0 < b < 1 && Abs[Im[a]] < Pi,1/(2 Pi I) Integrate[Exp[a z]/Sin[Pi z],{z,b- I Infinity,b+I infinity}]]
produces the result $$-\frac{1}{\pi \left(e^a+1\right)}$$ If we calculate the indefinite integral
indef=1/(2 Pi I) Integrate[Exp[a z]/Sin[Pi z],z]
we obtain $$\frac{i e^{(a+i \pi ) z} \, _2F_1\left(1,\frac{\pi -i a}{2 \pi };\frac{3}{2}-\frac{i a}{2 \pi };e^{2 i \pi z}\right)}{\pi (\pi -i a)}$$ Next, we set
temp = FullSimplify[(indef /. {z -> b + I R}) - (indef /. {z ->
b - I R})]
obtaining $$-\frac{e^{(a+i \pi ) (b+i R)} \, _2F_1\left(1,\frac{\pi -i a}{2 \pi };\frac{3}{2}-\frac{i a}{2 \pi };e^{2 i \pi (b+i R)}\right)-e^{(a+i \pi ) (b-i R)} \, _2F_1\left(1,\frac{\pi -i a}{2 \pi };\frac{3}{2}-\frac{i a}{2 \pi };e^{2 \pi (i b+R)}\right)}{\pi (a+i \pi )}$$
value2 = Assuming[0 < b < 1 && Abs[Im[a]] < Pi && R > 0,
Limit[temp, R -> Infinity]]]
gives $$\frac{e^{a/2} \Gamma \left(\frac{3}{2}-\frac{i a}{2 \pi }\right) \Gamma \left(\frac{i a+\pi }{2 \pi }\right)}{\pi (\pi -i a)}$$
value2 = Factor[FullSimplify[value2]]
gives $$\frac{e^a}{\pi \left(e^a+1\right)}$$ {value1, value2} $$\left\{-\frac{1}{\pi \left(e^a+1\right)},\frac{e ^a}{\pi \left(e^a+1\right)}\right\}$$ It can be shown by contour integration that value2 is the correct value.