Why would vtkXMLPolyDataReader not also read scalar arrays?

I don’t often use the visualization pipeline in VTK, so sorry if this is silly.

I have a datafile that has a “Temperature” array in point data - I can see it in ParaVew, but when I read it in via a Python script, no arrays show up?

from vtkmodules.vtkIOXML import vtkXMLPolyDataReader

r = vtkXMLPolyDataReader()
r.SetFileName("I_have_temperature_I_promise.vtp")
pd = r.GetOutput()
print(f"pd.GetPointData().GetNumberOfArrays(): {pd.GetPointData().GetNumberOfArrays()}")
print(f"pd.GetPointData().GetArrayName(0): {pd.GetPointData().GetArrayName(0)}")

output:

pd.GetPointData().GetNumberOfArrays(): 0
pd.GetPointData().GetArrayName(0): None

After you call r.SetFileName(...), call r.Update(). That will cause the file to be read and you should see your arrays.