• Making Mac Terminal and Windows CMD Support Unicode Charset Display in Python 3

    According to Python 3 unicode character representation, It is possible for the user to confront with Python exception when Terminal is trying to display such unicode data from Pyrfa. Here is the error:

    UnicodeEncodeError: 'ascii' codec can't encode character '\u21e7' in position 1: ordinal not in range(128)

    In this case the '\u21e7' is a unicode for an arrow character. It is a mandatory for the PyRFA users to configure their terminal in order to display these charset according to the Python 3 unicode support. Each of platform can properly display unicode via commands as follows:


    $ export PYTHONIOENCODING=utf-8


    C:\> chcp 65001