BUG: open csvfile with newline='' on Python 3

See http://docs.python.org/3/library/csv.html#csv.writer