Mesh.coordinates not working in conda

I am running code on a cluster at uni as I need the additional ram.
However when trying to save my data for post processing I’m having problems.

mesh = RectangleMesh(Point(-.3, 0), Point(1.3, 1), 16, 10 )

V = VectorFunctionSpace(mesh,"CG",1)
u = interpolate(Expression(("x[0]>0.98 ? -(.3/.32)*(x[0]-0.98) :0 ","0"),
                           degree=1),V)

w = interpolate(Expression(("x[0]< 0.02 ? -(.3/.32)*(x[0]-0.02) :0 ","0"),
                           degree=1),V)
                                                                           


ALE.move(mesh,u)
ALE.move(mesh,w)

plot(mesh)
plt.savefig('mesh.png')

Basically I just want a mesh denser near the boundaries x = 0,1 which appears fine

mesh

but when I try to extract the velocities, pressure and mesh values using

xy = mesh.coordinates()
uw = np.array([u(pt) for pt in xy])
P = np.array([p(pt) for pt in xy])
R = np.array([r(pt) for pt in xy])

tableur = xy
np.savetxt('2D_xy.dat',tableur)

etc. The size of the output is not what I expect. The file 2_D_xy.dat shoul have 160 entries but instead I get

1.250000000000001110e-02 5.999999999999999778e-01
1.875000000000000278e-02 5.999999999999999778e-01
1.875000000000000278e-02 6.999999999999999556e-01
1.250000000000001110e-02 6.999999999999999556e-01
1.000000000000000333e-01 6.999999999999999556e-01
1.875000000000000278e-02 8.000000000000000444e-01
1.000000000000000333e-01 8.000000000000000444e-01
2.000000000000000111e-01 8.000000000000000444e-01
1.000000000000000333e-01 9.000000000000000222e-01
2.000000000000000111e-01 9.000000000000000222e-01
1.875000000000000278e-02 1.000000000000000000e+00

This approach worked on ubuntu on my own laptop but doesn’t seem to be working with conda on the cluster. Any suggestions on potential workarounds?

I found a workaround

V = FunctionSpace(mesh,"CG",1)
xy = V.tabulate_dof_coordinates()

seems to be doing what I want. I will just have to sort the data a bit afterwards.
Putting it up incase it helps anyone else