So it starts off by way of contradiction, supposing $\pi\in \mathbb Q$, then by De-Moivre's theorem for rational powers: $$\left((\cos(2k\pi)+i\sin(2k\pi)\right)^{\pi}= \cos(2k\pi^2)+i\sin(2k\pi^2)=1^{\pi}$$
Here $k\in \mathbb Z$.
Then you must have $$\cos(2m\pi^2)+i\sin(2m\pi^2)= \cos(2p\pi^2)+i\sin(2p\pi^2)$$ for all $m,p$ that are integers.
However equating real parts gives $$cos(2m\pi^2)=\cos(2p\pi^2)$$, but this implies that $$2m\pi^2=2t\pi-2p\pi^2\quad \text {or} \quad 2m\pi^2=2t\pi+2p\pi^2$$
(for some integer $t$)
Which gives that $t= (m-p)\pi$ or $t= (m+p)\pi$; but choosing $m$ and $p$ appropriately such that for $\pi= \frac ab$ (where $a,b$ are coprime) you have $b$ doesn't divide $m\pm p$, which gives $t$ is not an integer contrary to assumption. The only remaining case is when $b=1$ which is trivially false as $3<\pi<4$ can be easily proven.