If any part of the question needs clarifying, there might be explanation in the post-script and of course ask if needed.
I understand how the Bernoulli equation is derived for incompressible fluid in a pipe. I will write the equation for a system where elevation is effectively constant. $$ P_1+\frac{\rho}{2}v_1^2=P_2+\frac{\rho}{2}v_2^2 $$ Now, I confused myself when considering the case where $P_2=0$ and starting from $F=\frac{dp}{dt}$ . I am thinking the infinitesimal change in momentum of the system as the piston moves by $dx$ (see post-script) is: $$ dp=\rho A_1 dx (v_2-v_1) $$ And so: $$ \frac{dp}{dt}=F=P_1 A_1=\rho A_1 \frac{dx}{dt}(v_2-v_1) = \rho A_1 v_1(v_2-v_1) $$ And so $P_1=\rho v_1(v_2-v_1) \neq \frac{\rho}{2}(v_2^2-v_1^2)$
My question is: where is my mistake?
Post-script:
The physical picture I was thinking of was a cylindrical pipe whose cross-section abruptly goes from [larger] $A_1$ to [smaller] $A_2$. The pressure in the volume with larger cross section is achieved by a piston, and there is no piston pushing on the volume of lower cross section.