diff options
author | Stefan H. Holek <stefan@epy.co.at> | 2012-11-12 13:54:37 +0100 |
---|---|---|
committer | Stefan H. Holek <stefan@epy.co.at> | 2012-11-12 13:54:37 +0100 |
commit | 89e72217be0c95226fa6db0062f3a58298f3e7c2 (patch) | |
tree | 4e90a0dc16aa1ccc3428e1f3a64c244d2ef13642 /setuptools/command/upload_docs.py | |
parent | be8173d7f6e5e971c5f028d5049d932cf5043efb (diff) | |
download | external_python_setuptools-89e72217be0c95226fa6db0062f3a58298f3e7c2.tar.gz external_python_setuptools-89e72217be0c95226fa6db0062f3a58298f3e7c2.tar.bz2 external_python_setuptools-89e72217be0c95226fa6db0062f3a58298f3e7c2.zip |
Can't use 'surrogateescape' in upload_docs either.
--HG--
branch : distribute
extra : rebase_source : 6e262cc5a15434bda3543868b29ea9d69c51e238
Diffstat (limited to 'setuptools/command/upload_docs.py')
-rw-r--r-- | setuptools/command/upload_docs.py | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/setuptools/command/upload_docs.py b/setuptools/command/upload_docs.py index e21a88ce..41d7f055 100644 --- a/setuptools/command/upload_docs.py +++ b/setuptools/command/upload_docs.py @@ -18,6 +18,7 @@ from base64 import standard_b64encode from pkg_resources import iter_entry_points from distutils import log +from distutils.errors import DistutilsError from distutils.errors import DistutilsOptionError try: @@ -25,17 +26,12 @@ try: except ImportError: from setuptools.command.upload import upload -if sys.version_info >= (3, 1): - errors = 'surrogateescape' -else: - errors = 'strict' - # This is not just a replacement for byte literals # but works as a general purpose encoder def b(s, encoding='utf-8'): if isinstance(s, unicode): - return s.encode(encoding, errors) + return s.encode(encoding) return s |