fb_pixel

Outputting python script results into text

Development | Web Development
Description

I have a want to save my python script's result into a txt file.

UnicodeEncodeError: 'charmap' codec can't encode character '\u02c9' in position 0: character maps to
Attachments
No attachments
Info
Description
Use UTF-8 encoding, for example:

print(status, file=open('c:\\temp\\status.txt', 'w'))

With encoding utf-8
print(status, file=open('c:\\temp\\status.txt', 'w', encoding='utf8'))


on November 20th, 2019 (9:36 pm)
All coments
This job has not been commented yet.