Polyline output wanted but got a list of points

You probably want the PolylineCurve class, alternatively call the ToNurbsCurve() method on the Polyline. The reason a single Polyline will output as a list of points, is that it is essentially what it is (it inherits from the Point3D list class) and the GHPython component will see it as an iterable and try to get/output its values (ie the points).