What is issue in square wave reconstruction?
Well this goes to show that Fourier series is just approximation that gets more and more correct when you add more harmonics. Take a look at this:



$\dfrac{4\sin\theta}{\pi}$ is just first harmonic.

Harmonics are integer multiple of base frequency as you can see: $\sin3\theta$, $\sin5\theta$ etc. And the more of them you add to the first harmonic the more your final signal will look like a square wave.

The square wave you showed on the left will have infinitely many harmonics, and the one on the right is just a sum of first few.

GIF author Cmglee