TypeError: ‘newline’ is an invalid keyword argument for this function

This may be able to help you out. It seems like that is an invalid variable name for what you are trying to do.

The error occurs because newline=”” is an invalid option for csv.writer(). Changing that should solve the problem. As seen here.

Leave a Comment