Automate placing Pipe Accessory (Valves)

It is possible to input a list of FamilyTypes so that shouldn’t be the problem. I think it gives the error because the python code will also try to change the size of the connectors on the family and changing the size of the family when it’s a type parameter is probably the reason for the error.
If you are somewhat comfortable with Python then you could try removing the lines that set the Connector sizes and see if that works:
image