domain $D:=\mathbb{C} - \{ 1, e^{\frac{2}{3}\pi i}, e^{\frac{4}{3}\pi i} \}$.
Here is the proof of the fact that the primitive function of $f(z):=\dfrac{1}{z^3-1}$ doesn't exist on $D$.
Proof
Suppose there exists $g(z)$ such that $g(z)$ is regular on $D$ and $g'(z)=f(z)$.
Let $C:=\{z\in \mathbb{C} \ | \ |z-1|=r \}$, where $r$ is small enough.
From the residue theorem, $\displaystyle\int_C f(z)dz=2\pi i \text{Res}(f, 1)=\dfrac{2}{3} \pi i$.
On the other hand, from the Cauchy's integral theorem, $\displaystyle\int_C f(z) dz =\displaystyle\int_C g'(z) dz =0. \cdots \ast$
This is contradictory. ■
I cannot understand why $\ast$ holds. On the domain $D$, the internal of $C$ is not simply connected, so I think that we cannot use the Cauchy's integral theorem.
It follows from the fact $$\int_{|z-1|=r} g'(z) dz =\int_0^{2\pi } g'(1+re^{it} ) ire^{it} dt =g(1+re^{it} )|_0^{2\pi } = g(1+re^0 ) -g(1+re^{2\pi i }) =g(1+r) -g(1+r) =0 $$