Failure of Newton-Leibniz formula Suppose that $f : \mathbb{R} \rightarrow \mathbb{R}$ is differentiable but  $f \notin C^1 ( \mathbb{R} )$ . It means that $f'$ exist but it is not continuous.

Question 1 Is function $f'$ locally integrable. I.e. does there exist for every $a , b \in \mathbb{R}$

$$ \int_{a}^{b} f'(x) dx $$

I think, I should ask about existence of Lebesgue integral.

Question 2 If it exist, does the Newton-Leibniz formula holds?

$$ \int_{a}^{b} f'(x) dx = f(b) - f(a) $$

Comment. I am asking because I wanted to prove Cauchy's integral theorem using Stokes' theorem. One told me that I am not allowed to use Stokes' theorem if derivatives are not continuous.. So I wonder whether it is important. The simplest case of Stokes' theorem is Newton-Leibniz formula.
Question 1. If $f=x^2\sin(x^{-2})$, then $f'$ exists everywhere (including $x=0$) but $f'$ is not Lebesgue integrable on $[0,1]$ (precisely because of the singularity at $x=0$).(Taken from here).

Question 2. By this thread, $f$ is absolutely continuous on each segment $[a,b]$. Then the positive answer follows from the fundamental theorem of calculus for Lebesgue integral (see, for instance, [?, Theorem 6.10], [Ba], [Be, Theorem 2]).

References

[Ba] Diómedes Bárcenas, The Fundamental Theorem of
Calculus for Lebesgue Integral, Divulgaciones Matemáticas 8:1 (2000), 75-85.

[Ba] Stephen Becker, Absolutely continuous functions, Radon-Nikodym Derivative, APPM 5450 Spring 2016 Applied Analysis 2.

[?] “Section 6.5. Integrating Derivatives: Diﬀerentiating Indeﬁnite Integrals”.
Q1: Since $f$ is differentiable on $(a,b)$ then $f(x):=\int_a^x{f'(t)dt}$, where $f'$ is absolutely continuous on $(a,b)$ (we can guarantee this case by Lebesgue theorem), so the answer is Yes $f$ is locally integrable in both senses Riemann and Lebesgue.

Q2: No cannot apply this. Since $f$ is not continuous on $(a,b)$. You may refer to the fundamental theorem of integral calculus.