from __future__ import absolute_import

VERSION = (6, 3, 1)
__version__ = VERSION
__versionstr__ = '.'.join(map(str, VERSION))

import sys

if (2, 7) <= sys.version_info < (3, 2):
    # On Python 2.7 and Python3 < 3.2, install no-op handler to silence
    # `No handlers could be found for logger "elasticsearch"` message per
    # <https://docs.python.org/2/howto/logging.html#configuring-logging-for-a-library>
    import logging
    logger = logging.getLogger('elasticsearch')
    logger.addHandler(logging.NullHandler())

from .client import Elasticsearch
from .transport import Transport
from .connection_pool import ConnectionPool, ConnectionSelector, \
    RoundRobinSelector
from .serializer import JSONSerializer
from .connection import Connection, RequestsHttpConnection, \
    Urllib3HttpConnection
from .exceptions import *


@@ -1,12 +1,26 @@
+#flake8: noqa%0A
 from __futur
@@ -146,309 +146,194 @@
 ort 
-sys%0A%0Aif (2, 7) %3C= sys.version_info %3C (3, 2):%0A    # On Python 2.7 and Python3 %3C 3.2, install no-op handler to silence%0A    # %60No handlers could be found for logger %22elasticsearch%22%60 message per%0A    # %3Chttps://docs.python.org/2/howto/logging.html#configuring-logging-for-a-library%3E%0A    import logging%0A    
+logging%0Atry:  # Python 2.7+%0A    from logging import NullHandler%0Aexcept ImportError:%0A    class NullHandler(logging.Handler):%0A        def emit(self, record):%0A            pass%0A%0Aimport sys%0A%0A
 logg
@@ -372,20 +372,16 @@
 earch')%0A
-    
 logger.a

Add NullHandler to logger for all Python versions (#896)