Karthikeyan Singaravelan <tir.kar...@gmail.com> added the comment:
Can you please attach a sample script to reproduce the behavior difference? With below script a dictionary is passed then dict.keys() supports subtraction over a list to return the difference. I am not sure how you have received a list with dict.keys() in Python 3.7. import csv fields = ["c", "d"] with open('test.csv', 'w') as f: writer = csv.DictWriter(f, fieldnames=fields, extrasaction='raise') writer.writeheader() writer.writerow({"n": 1}) ---------- nosy: +xtreak _______________________________________ Python tracker <rep...@bugs.python.org> <https://bugs.python.org/issue38717> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com