From 1e05d48d2deac8486c9552a384a14848db09d558 Mon Sep 17 00:00:00 2001 From: Richard Belleville Date: Tue, 30 Oct 2018 17:53:50 -0700 Subject: [PATCH] Revert "Configure module level loggers with basicConfig()" This reverts commit a20e2073c1c53cbdd81a4fb750982a0b13e0c24e. --- src/python/grpcio/grpc/_channel.py | 1 - src/python/grpcio/grpc/_common.py | 1 - src/python/grpcio/grpc/_cython/_cygrpc/grpc_string.pyx.pxi | 1 - src/python/grpcio/grpc/_cython/_cygrpc/server.pyx.pxi | 1 - src/python/grpcio/grpc/_plugin_wrapping.py | 1 - src/python/grpcio/grpc/_server.py | 1 - src/python/grpcio/grpc/framework/foundation/callable_util.py | 1 - src/python/grpcio/grpc/framework/foundation/logging_pool.py | 1 - src/python/grpcio/grpc/framework/foundation/stream_util.py | 1 - src/python/grpcio_testing/grpc_testing/_channel/_invocation.py | 1 - src/python/grpcio_testing/grpc_testing/_server/_rpc.py | 1 - src/python/grpcio_testing/grpc_testing/_time.py | 1 - src/python/grpcio_tests/tests/interop/server.py | 1 - 13 files changed, 13 deletions(-) diff --git a/src/python/grpcio/grpc/_channel.py b/src/python/grpcio/grpc/_channel.py index eeeb4ddb33d..c625cd3e370 100644 --- a/src/python/grpcio/grpc/_channel.py +++ b/src/python/grpcio/grpc/_channel.py @@ -24,7 +24,6 @@ from grpc import _grpcio_metadata from grpc._cython import cygrpc from grpc.framework.foundation import callable_util -logging.basicConfig() _LOGGER = logging.getLogger(__name__) _USER_AGENT = 'grpc-python/{}'.format(_grpcio_metadata.__version__) diff --git a/src/python/grpcio/grpc/_common.py b/src/python/grpcio/grpc/_common.py index 3805c7e82a7..8358cbec5b3 100644 --- a/src/python/grpcio/grpc/_common.py +++ b/src/python/grpcio/grpc/_common.py @@ -20,7 +20,6 @@ import six import grpc from grpc._cython import cygrpc -logging.basicConfig() _LOGGER = logging.getLogger(__name__) CYGRPC_CONNECTIVITY_STATE_TO_CHANNEL_CONNECTIVITY = { diff --git a/src/python/grpcio/grpc/_cython/_cygrpc/grpc_string.pyx.pxi b/src/python/grpcio/grpc/_cython/_cygrpc/grpc_string.pyx.pxi index 334e561baad..00a1b23a67b 100644 --- a/src/python/grpcio/grpc/_cython/_cygrpc/grpc_string.pyx.pxi +++ b/src/python/grpcio/grpc/_cython/_cygrpc/grpc_string.pyx.pxi @@ -14,7 +14,6 @@ import logging -logging.basicConfig() _LOGGER = logging.getLogger(__name__) # This function will ascii encode unicode string inputs if neccesary. diff --git a/src/python/grpcio/grpc/_cython/_cygrpc/server.pyx.pxi b/src/python/grpcio/grpc/_cython/_cygrpc/server.pyx.pxi index 5779437b922..ce701724fd3 100644 --- a/src/python/grpcio/grpc/_cython/_cygrpc/server.pyx.pxi +++ b/src/python/grpcio/grpc/_cython/_cygrpc/server.pyx.pxi @@ -18,7 +18,6 @@ import logging import time import grpc -logging.basicConfig() _LOGGER = logging.getLogger(__name__) cdef class Server: diff --git a/src/python/grpcio/grpc/_plugin_wrapping.py b/src/python/grpcio/grpc/_plugin_wrapping.py index 88ab4d8371f..916ee080b60 100644 --- a/src/python/grpcio/grpc/_plugin_wrapping.py +++ b/src/python/grpcio/grpc/_plugin_wrapping.py @@ -20,7 +20,6 @@ import grpc from grpc import _common from grpc._cython import cygrpc -logging.basicConfig() _LOGGER = logging.getLogger(__name__) diff --git a/src/python/grpcio/grpc/_server.py b/src/python/grpcio/grpc/_server.py index daa000a6e1b..7276a7fd90e 100644 --- a/src/python/grpcio/grpc/_server.py +++ b/src/python/grpcio/grpc/_server.py @@ -27,7 +27,6 @@ from grpc import _interceptor from grpc._cython import cygrpc from grpc.framework.foundation import callable_util -logging.basicConfig() _LOGGER = logging.getLogger(__name__) _SHUTDOWN_TAG = 'shutdown' diff --git a/src/python/grpcio/grpc/framework/foundation/callable_util.py b/src/python/grpcio/grpc/framework/foundation/callable_util.py index fb8d5f7c1e3..24daf3406f8 100644 --- a/src/python/grpcio/grpc/framework/foundation/callable_util.py +++ b/src/python/grpcio/grpc/framework/foundation/callable_util.py @@ -21,7 +21,6 @@ import logging import six -logging.basicConfig() _LOGGER = logging.getLogger(__name__) diff --git a/src/python/grpcio/grpc/framework/foundation/logging_pool.py b/src/python/grpcio/grpc/framework/foundation/logging_pool.py index 7702d1785f9..216e3990db0 100644 --- a/src/python/grpcio/grpc/framework/foundation/logging_pool.py +++ b/src/python/grpcio/grpc/framework/foundation/logging_pool.py @@ -17,7 +17,6 @@ import logging from concurrent import futures -logging.basicConfig() _LOGGER = logging.getLogger(__name__) diff --git a/src/python/grpcio/grpc/framework/foundation/stream_util.py b/src/python/grpcio/grpc/framework/foundation/stream_util.py index 9184f958737..1faaf29bd7e 100644 --- a/src/python/grpcio/grpc/framework/foundation/stream_util.py +++ b/src/python/grpcio/grpc/framework/foundation/stream_util.py @@ -19,7 +19,6 @@ import threading from grpc.framework.foundation import stream _NO_VALUE = object() -logging.basicConfig() _LOGGER = logging.getLogger(__name__) diff --git a/src/python/grpcio_testing/grpc_testing/_channel/_invocation.py b/src/python/grpcio_testing/grpc_testing/_channel/_invocation.py index d7205ca5793..191b1c17264 100644 --- a/src/python/grpcio_testing/grpc_testing/_channel/_invocation.py +++ b/src/python/grpcio_testing/grpc_testing/_channel/_invocation.py @@ -18,7 +18,6 @@ import threading import grpc _NOT_YET_OBSERVED = object() -logging.basicConfig() _LOGGER = logging.getLogger(__name__) diff --git a/src/python/grpcio_testing/grpc_testing/_server/_rpc.py b/src/python/grpcio_testing/grpc_testing/_server/_rpc.py index 736b714dc6d..b856da100f0 100644 --- a/src/python/grpcio_testing/grpc_testing/_server/_rpc.py +++ b/src/python/grpcio_testing/grpc_testing/_server/_rpc.py @@ -18,7 +18,6 @@ import threading import grpc from grpc_testing import _common -logging.basicConfig() _LOGGER = logging.getLogger(__name__) diff --git a/src/python/grpcio_testing/grpc_testing/_time.py b/src/python/grpcio_testing/grpc_testing/_time.py index 9692c34e6f3..75e6db34586 100644 --- a/src/python/grpcio_testing/grpc_testing/_time.py +++ b/src/python/grpcio_testing/grpc_testing/_time.py @@ -21,7 +21,6 @@ import time as _time import grpc import grpc_testing -logging.basicConfig() _LOGGER = logging.getLogger(__name__) diff --git a/src/python/grpcio_tests/tests/interop/server.py b/src/python/grpcio_tests/tests/interop/server.py index 768cdaf468d..fd28d498a18 100644 --- a/src/python/grpcio_tests/tests/interop/server.py +++ b/src/python/grpcio_tests/tests/interop/server.py @@ -25,7 +25,6 @@ from tests.interop import methods from tests.interop import resources from tests.unit import test_common -logging.basicConfig() _ONE_DAY_IN_SECONDS = 60 * 60 * 24 _LOGGER = logging.getLogger(__name__)