Issue
What does error TypeError: 'NoneType' object is not iterable
mean?
I am getting it on this Python code:
def write_file(data, filename): # creates file and writes list to it
with open(filename, 'wb') as outfile:
writer = csv.writer(outfile)
for row in data: # ABOVE ERROR IS THROWN HERE
writer.writerow(row)
Solution
It means the value of data
is None
.
Answered By - vanza
0 comments:
Post a Comment
Note: Only a member of this blog may post a comment.