Tuesday, July 3, 2007

python ValueError: universal newline mode 'U'

print open(featurefile, 'wU').writelines()
ValueError: universal newline mode can only be used with modes starting with 'r'
take out U will solve the issue.

No comments: