aboutsummaryrefslogtreecommitdiffstats
path: root/setuptools/ssl_support.py
diff options
context:
space:
mode:
authorVinay Sajip <vinay_sajip@yahoo.co.uk>2013-06-15 15:34:53 +0100
committerVinay Sajip <vinay_sajip@yahoo.co.uk>2013-06-15 15:34:53 +0100
commit8e657eac1ef02faedca99df319fff6b63f4a4305 (patch)
treef3f2ed97342421c6b65c9caaab8ae5d830f04059 /setuptools/ssl_support.py
parentc04abca662dcbffd00d928e06fbf32b9f49f8e57 (diff)
downloadexternal_python_setuptools-8e657eac1ef02faedca99df319fff6b63f4a4305.tar.gz
external_python_setuptools-8e657eac1ef02faedca99df319fff6b63f4a4305.tar.bz2
external_python_setuptools-8e657eac1ef02faedca99df319fff6b63f4a4305.zip
Initial commit. All tests pass on 2.7, 3.2 and 3.3, though there are some atexit errors in the multiprocessing module in 2.7/3.2 (seemingly unrelated to setuptools).
--HG-- branch : single-codebase
Diffstat (limited to 'setuptools/ssl_support.py')
-rw-r--r--setuptools/ssl_support.py7
1 files changed, 6 insertions, 1 deletions
diff --git a/setuptools/ssl_support.py b/setuptools/ssl_support.py
index 6dca5fab..af718a4b 100644
--- a/setuptools/ssl_support.py
+++ b/setuptools/ssl_support.py
@@ -1,8 +1,13 @@
-import sys, os, socket, urllib2, atexit, re
+import sys, os, socket, atexit, re
import pkg_resources
from pkg_resources import ResolutionError, ExtractionError
try:
+ import urllib2
+except ImportError:
+ import urllib.request as urllib2
+
+try:
import ssl
except ImportError:
ssl = None