diff options
author | Thomas <twvd@users.noreply.github.com> | 2019-11-07 00:32:05 +0100 |
---|---|---|
committer | Paul McGuire <ptmcg@users.noreply.github.com> | 2019-11-06 17:32:05 -0600 |
commit | d7fb0d83fd12cb7a78e917414e0c303106df0693 (patch) | |
tree | 84792687e8940b2c68db47c1ced5d3614ffe255f | |
parent | c9142bd72cb959227266465726412127ebf85d35 (diff) | |
download | pyparsing-git-d7fb0d83fd12cb7a78e917414e0c303106df0693.tar.gz |
Explicitly specify UTF-8 encoding when opening README file (#163)
* Explicitly specify UTF-8 encoding when opening README file
* Fix Python 2.6.x+ support for setup.py
* Removed stray unicode space character from README.rst
-rw-r--r-- | README.rst | 2 | ||||
-rw-r--r-- | setup.py | 3 |
2 files changed, 3 insertions, 2 deletions
@@ -7,7 +7,7 @@ Introduction ============ The pyparsing module is an alternative approach to creating and -executing simple grammars, vs. the traditional lex/yacc approach, or the +executing simple grammars, vs. the traditional lex/yacc approach, or the use of regular expressions. The pyparsing module provides a library of classes that client code uses to construct the grammar directly in Python code. @@ -4,12 +4,13 @@ from setuptools import setup from pyparsing import __version__ as pyparsing_version +from io import open # The directory containing this file README_name = __file__.replace("setup.py", "README.rst") # The text of the README file -with open(README_name) as README: +with open(README_name, encoding='utf8') as README: pyparsing_main_doc = README.read() modules = ["pyparsing",] |