cpython: fe740c1cee02 (original) (raw)

Mercurial > cpython

changeset 70204:fe740c1cee02

Issue #12112: packaging reads and writes setup.cfg using UTF-8 [#12112]

Victor Stinner victor.stinner@haypocalc.com
date Thu, 19 May 2011 18:45:32 +0200
parents 946baaeb1d10
children 01d61096140a
files Lib/packaging/config.py Lib/packaging/create.py Lib/packaging/tests/support.py Lib/packaging/tests/test_config.py Lib/packaging/tests/test_create.py
diffstat 5 files changed, 11 insertions(+), 11 deletions(-)[+] [-] Lib/packaging/config.py 2 Lib/packaging/create.py 2 Lib/packaging/tests/support.py 4 Lib/packaging/tests/test_config.py 2 Lib/packaging/tests/test_create.py 12

line wrap: on

line diff

--- a/Lib/packaging/config.py +++ b/Lib/packaging/config.py @@ -282,7 +282,7 @@ class Config: for filename in filenames: logger.debug(" reading %s", filename)

if os.path.split(filename)[-1] == 'setup.cfg': self._read_setup_cfg(parser, filename)

--- a/Lib/packaging/create.py +++ b/Lib/packaging/create.py @@ -276,7 +276,7 @@ class MainProgram: return shutil.move(_FILENAME, '%s.old' % _FILENAME)

--- a/Lib/packaging/tests/support.py +++ b/Lib/packaging/tests/support.py @@ -138,7 +138,7 @@ class TempdirManager: d = tempfile.mkdtemp(dir=self._basetempdir) return d

path can be a string, a tuple or a list; if it's a tuple or list, @@ -146,7 +146,7 @@ class TempdirManager: """ if isinstance(path, (list, tuple)): path = os.path.join(*path)

def create_dist(self, **kw):

--- a/Lib/packaging/tests/test_config.py +++ b/Lib/packaging/tests/test_config.py @@ -183,7 +183,7 @@ class ConfigTestCase(support.TempdirMana 'setup-hook': 'packaging.tests.test_config.hook'} if kwargs: opts.update(kwargs)

def get_dist(self): dist = Distribution()

--- a/Lib/packaging/tests/test_create.py +++ b/Lib/packaging/tests/test_create.py @@ -91,7 +91,7 @@ class CreateTestCase(support.TempdirMana def test_convert_setup_py_to_cfg(self): self.write_file((self.wdir, 'setup.py'), dedent("""

long_description = '''My super Death-scription @@ -124,12 +124,12 @@ class CreateTestCase(support.TempdirMana }, scripts=['my_script', 'bin/run'], )

# FIXME don't use sets @@ -171,7 +171,7 @@ class CreateTestCase(support.TempdirMana def test_convert_setup_py_to_cfg_with_description_in_readme(self): self.write_file((self.wdir, 'setup.py'), dedent("""

@@ -191,7 +191,7 @@ class CreateTestCase(support.TempdirMana ('share/man', ['pyxfoil.1']), ], )

My super Death-scription @@ -202,7 +202,7 @@ ho, baby sys.stdin.seek(0) # FIXME Out of memory error. main()

self.assertEqual(lines, set(['',