The problem is that in your script the function:
loft = ghcomp.LoftOptions(True,False,0,0,0)
returns a string instead of the expected type LoftOptions. I’m investigation the problem but you could consider using the rhinoscriptsyntax AddLoftSurface function instead.
Hope this helps