diff options
author | Ben Nemec <bnemec@redhat.com> | 2018-03-22 16:23:15 +0000 |
---|---|---|
committer | Stephen Finucane <stephenfin@redhat.com> | 2018-03-27 10:54:57 +0000 |
commit | 10fce39a7b0c100d982d1d987eed57e31bfb9779 (patch) | |
tree | 4ad67def7646a9b835f9f2e6f72a7ddcced83fb4 /doc/source/user | |
parent | 1f2c7314853d254c58f3adf7f03ca80589cb6f36 (diff) | |
download | pbr-10fce39a7b0c100d982d1d987eed57e31bfb9779.tar.gz |
Explicitly read setup.cfg as utf-8 on Python 3
Per the referenced bug, relying on the terminal encoding to read
setup.cfg is not safe. Unfortunately, Python 2 doesn't accept an
encoding when reading config files so we need a fallback path for
that version.
Change-Id: If49344db2f9139c0557f6acd17671163e02468a5
Closes-Bug: 1745396
Diffstat (limited to 'doc/source/user')
-rw-r--r-- | doc/source/user/using.rst | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/doc/source/user/using.rst b/doc/source/user/using.rst index d0ff3bd..f8da6de 100644 --- a/doc/source/user/using.rst +++ b/doc/source/user/using.rst @@ -119,6 +119,11 @@ such as the ``extract_mesages`` section provided by Babel__. # A comment on a dedicated line value3 +.. note:: + + On Python 3 ``setup.cfg`` is explicitly read as UTF-8. On Python 2 the + encoding is dependent on the terminal encoding. + __ http://setuptools.readthedocs.io/en/latest/setuptools.html#configuring-setup-using-setup-cfg-files __ http://babel.pocoo.org/en/latest/setup.html |