From 8e657eac1ef02faedca99df319fff6b63f4a4305 Mon Sep 17 00:00:00 2001 From: Vinay Sajip Date: Sat, 15 Jun 2013 15:34:53 +0100 Subject: 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 --- setuptools/ssl_support.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'setuptools/ssl_support.py') 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,7 +1,12 @@ -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: -- cgit v1.2.3