import inspect
import sys
if sys.version_info[0] == 2:
    from .python2 import httplib2
else:
    from .python3 import httplib2
globals().update(inspect.getmembers(httplib2))

import os
import sys

path = os.path.dirname(__file__)+os.path.sep+'python'+str(sys.version_info[0])
sys.path.insert(0, path)
del sys.modules['httplib2']
import httplib2

Rewrite python version dependent import
Rewrite python version dependent import

The top level of this external includes a __init__.py so that
it may be imported with only 'externals' in sys.path.

However it copies the contents of the python version dependent httplib2
code, resulting in module level variables appearing in two different
namespaces.  As a result, regarding bug 66161, the 'httplib2.debuglevel'
modified in pywikibot code is a different variable to the
'httplib2.debuglevel' used by the httplib2 module.

Instead of copying the python version dependent httplib2, re-import the
python version dependent httplib2.

Change-Id: Ic520505545a5f50f669a01375b253426ecad15ed
