Fall back to urllib instead of urllib2 for Python 3 urllib.parse