I know this has been answered on the site (see here: How to integrate $\int_0^\infty\frac{x^{1/3}dx}{1+x^2}$?) but I want to know why what I did is not leading to a sensible result.
I used the splitting the logarithm trick, i.e. examining $$ \int_\Gamma\frac{z^{1/3}\log z}{1+z^2}\mathrm dz=2\pi i\left( \frac{\sqrt{3}}{2}+\frac{i}{2}\right )=\pi(\sqrt{3} i-1) $$ by the residue theorem and using the sane branch cut on the positive real axis. Now by Jordan's theorem the contribution of the arc should be zero leaving us with $$ \int_0^R \frac{x^{1/3}\log x}{1+x^2}\mathrm dx+\int_{-R}^0\frac{x^{1/3}\log x}{1+x^2}\mathrm dx\\ = \int_0^R \frac{x^{1/3}\log x}{1+x^2}\mathrm dx+\int_{0}^R\frac{x^{1/3}\log(- x)}{1+x^2}\mathrm dx\\ =2\int_0^R \frac{x^{1/3}\log x}{1+x^2}\mathrm dx+\frac{\pi}{2}i\int_0^R\frac{x^{1/3}}{1+x^2}\mathrm dx $$ which by equating real and imaginary parts should imply my integral is $$ 2\int_0^R \frac{x^{1/3}\log x}{1+x^2}\mathrm dx+\frac{\pi}{2}i\int_0^R\frac{x^{1/3}}{1+x^2}\mathrm dx=\pi(\sqrt{3} i-1)\\ \implies \int_0^\infty\frac{x^{1/3}}{1+x^2}\mathrm dx=2\sqrt{3} $$ which is false. Additionally, this would imply that $$ \int_0^R \frac{x^{1/3}\log x}{1+x^2}\mathrm dx=-\frac{\pi}{2} $$ which is also false.
Where did I go wrong? My guess is somewhere in the branch cutting, possibly with taking the cube root of 3 in the residue theorem?