Helllo,
I get this error when running a script on a Debian 11 host (Python 3.5.3), apparently because the web site I call through requests() returns UTF8 data:
UnicodeEncodeError: 'ascii' codec can't encode character '\u2019' in position 112: ordinal not in range(128)
In this article, the only thing that works is this:
~# export PYTHONIOENCODING=utf8
How can I make it 1) sticky, and 2) possible to run the script through cron?
Thank you.
I get this error when running a script on a Debian 11 host (Python 3.5.3), apparently because the web site I call through requests() returns UTF8 data:
UnicodeEncodeError: 'ascii' codec can't encode character '\u2019' in position 112: ordinal not in range(128)
In this article, the only thing that works is this:
~# export PYTHONIOENCODING=utf8
How can I make it 1) sticky, and 2) possible to run the script through cron?
Thank you.