The propagator in non-relativistic quantum mechanics is:
$$G(\mathbf{x}, t; \mathbf{x}', t') = \left\langle \mathbf{x} \Big| e^{-i H (t - t') / \hbar} \Big| \mathbf{x}' \right\rangle.$$
Adding the completeness relation between the states and the operator
$$\int \frac{d^3p}{(2\pi)^3} \, | \mathbf{p} \rangle \langle \mathbf{p} | = I$$
we obtain
$$G(\mathbf{x}, t; \mathbf{x}', t') = \frac{1}{(2\pi)^{3}} \int d^3p \, e^{-i \frac{\mathbf{p}^2}{2m} \frac{(t - t')}{\hbar}} e^{i \mathbf{p} \cdot (\mathbf{x} - \mathbf{x}') / \hbar}.$$
This integral is not convergent, and to solve it we need to perform an analytical continuation, for example we can take the time $t - t_0$ and replace it with $t - t_0+i\epsilon$, with $\epsilon$ tending to $0$. at this point the integral is convergent.
My question is: having obtained an undefined result, why do we continue to go ahead and "correct" the problem ad hoc? I can't justify the fact that we are in effect changing an ad hoc result. Maybe that $i\epsilon$ term should appear first, during the insertion of the completeness relations?