I'm reading Purcell's Electricity and Magnetism book (5.9 "Interaction between a moving charge and other moving charges") where he explains how due to relativistic effects (length contraction) a magnetic force acting on a particle that moves near the wire in the lab frame (where the wire is stationary) is the result of an electric force that acts on the particle in its rest frame.
He starts with an uncharged wire (the charge densities of the electrons and the protons are equal in magnitude). Then he shows that in the frame of reference of the moving particle the linear densities of the electrons and protons are different and thus the wire looks charged. I have two questions:
If the wire is neutral in the lab frame, how can it become charged in the moving frame? Isn't it a contradiction of the principle of charge invariance? I understand that the linear densities must change, but the total charge should not change.
Let's examine a simpler setup. Suppose we have a neutral wire with protons and electrons both at rest in the lab frame (protons' and electrons' linear densities are $\lambda_0$ and $-\lambda_0$ respectively). Suppose we also have a charged particle at rest (also in the lab frame) near the wire. Suppose that all the electrons suddenly acquire some constant speed $v$ in the lab frame (for example, we turn on the electric field). So now we have stationary ions, moving electrons and a stationary charged particle (still, in the lab frame). Then we can use the same length contraction argument and claim that after acquiring the speed, the electron's density is now $-\gamma\lambda_0$. But then, using Purcell's argument we can claim that the total linear density of charge in the wire in the lab frame is $\lambda'=\lambda_0-\gamma\lambda_0=\lambda_0(1-\gamma)\neq 0$ therefore the wire becomes charged (again, using the same argument as Purcell). Therefore the stationary particle (we're still in the lab frame) will feel an electric force. However this seems to be wrong. What's wrong with this reasoning?