code: def print_csv(headers, data_list, parse_row_fn):
      
      try:
          writer = csv.writer(sys.stdout)
          writer.writerow(headers)
          for data in data_list:
              writer.writerow(parse_row_fn(data))
      except csv.Error as e:
          raise CliException('Error writing CSV: {}'.format(e))
docs: Takes headers, data, and a row parsing function, and prints data
      to the console in a csv format.