Let us consider the worldline $x^\mu(\lambda)$ of an observer moving in an arbitrary manner (i.e. possibly non-inertial). If we want to write down the proper time interval measured by that observer between two points $\lambda_1$ and $\lambda_2$ on its trajectory, we use the formula $$\Delta\tau=\int\limits_{\lambda_1}^{\lambda_2}d\lambda\sqrt{\eta_{\mu\nu}\frac{dx^\mu}{d\lambda}\frac{dx^\nu}{d\lambda}}$$ instead of $$\Delta\tau=\int\limits_{\lambda_1}^{\lambda_2}d\lambda\sqrt{g_{\mu\nu}(x)\frac{dx^\mu}{d\lambda}\frac{dx^\nu}{d\lambda}}.$$
Aren't acceleration effects mimicked by the presence of a gravitational field ala the equivalence principle? If so, should we not use the second formula? I am sure that I hold a severe foundational misunderstanding here. I think I am equating "acceleration $\Longleftrightarrow$ presence of gravity" which is wrong?