Changing print statements from the old py2 'print' keyword syntax into the newer 'print' function syntax, also changing one try-except exception catching from the old 'comma' syntax to the newer 'as' keyword syntax. Now this module can be imported in both python3 and python2 safely, prior to that it was not compatible with python3.
Note: the 'as' assignment within an exception catching is not compatible with python <= 2.5 but it is better to have this module compatible with python3 than with python <= 2.5 (https://peps.python.org/pep-3110/)
Changing print statements from the old py2 'print' keyword syntax into the newer 'print' function syntax, also changing one try-except exception catching from the old 'comma' syntax to the newer 'as' keyword syntax. Now this module can be imported in both python3 and python2 safely, prior to that it was not compatible with python3.
Note: the 'as' assignment within an exception catching is not compatible with python <= 2.5 but it is better to have this module compatible with python3 than with python <= 2.5 (https://peps.python.org/pep-3110/)