Sayth Renshaw wrote:
def dataAttr(roots): """Get the root object and iter items.""" with open("output/first2.csv", 'w', newline='') as csvf: race_writer = csv.writer(csvf, delimiter=',') for meet in roots.iter("meeting"):
The value of roots you're passing in here is a generator object that yields root instances, not a root instance itself. So it looks like you need another level of iteration: for root in roots: for meet in root.iter("meeting"): ... -- Greg -- https://mail.python.org/mailman/listinfo/python-list