diff options
author | Victor Stinner <vstinner@redhat.com> | 2019-09-25 02:10:35 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-09-25 02:10:35 +0200 |
commit | 52ad33abbfb6637d74932617c7013bae0ccf6e32 (patch) | |
tree | 2540db0d6a9b7c620debf75e63ab866a85f1f677 /Lib/sysconfig.py | |
parent | bpo-36871: Avoid duplicated 'Actual:' in assertion message (GH-16361) (diff) | |
download | cpython-52ad33abbfb6637d74932617c7013bae0ccf6e32.tar.gz cpython-52ad33abbfb6637d74932617c7013bae0ccf6e32.tar.bz2 cpython-52ad33abbfb6637d74932617c7013bae0ccf6e32.zip |
bpo-38234: test_embed: test pyvenv.cfg and pybuilddir.txt (GH-16366)
Add test_init_pybuilddir() and test_init_pyvenv_cfg() to test_embed
to test pyvenv.cfg and pybuilddir.txt configuration files.
Fix sysconfig._generate_posix_vars(): pybuilddir.txt uses UTF-8
encoding, not ASCII.
Diffstat (limited to 'Lib/sysconfig.py')
-rw-r--r-- | Lib/sysconfig.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Lib/sysconfig.py b/Lib/sysconfig.py index e76e6927cb1..b9e2fafbc08 100644 --- a/Lib/sysconfig.py +++ b/Lib/sysconfig.py @@ -412,7 +412,7 @@ def _generate_posix_vars(): pprint.pprint(vars, stream=f) # Create file used for sys.path fixup -- see Modules/getpath.c - with open('pybuilddir.txt', 'w', encoding='ascii') as f: + with open('pybuilddir.txt', 'w', encoding='utf8') as f: f.write(pybuilddir) def _init_posix(vars): |