Let, $x = \cos(\theta)$ and
$$s = \int^{1}_{-1}\frac{1 \ dx}{\sqrt{1-x^2}}.$$
If we let $1 = \cos(2\pi)$ and $-1 = \cos(\pi)$, we obtain: $$s = -\int^{2\pi}_{\pi}1 dx = -\pi.$$
However, if we let $1 = \cos(0)$ and $-1 = \cos(\pi)$, we obtain: $$s = -\int^{0}_{\pi}1 dx = \pi.$$
Your substitution requires the use of the inverse cosine function in the transformed limits [ $ \theta \ = \ \arccos(x) \ $ ] . So $ \ \arccos(1) \ = \ 0 \ $ and $ \ \arccos(-1) \ = \ \pi \ $ , making your second definite integral the correct one.