Added null handler to loggers

This commit is contained in:
Andrew Murray 2015-12-09 19:20:29 +11:00
parent 112240d3a2
commit 20dcf76cef
7 changed files with 7 additions and 0 deletions

View File

@ -32,6 +32,7 @@ import logging
import warnings
logger = logging.getLogger(__name__)
logger.addHandler(logging.NullHandler())
class DecompressionBombWarning(RuntimeWarning):

View File

@ -36,6 +36,7 @@ import sys
import struct
logger = logging.getLogger(__name__)
logger.addHandler(logging.NullHandler())
MAXBLOCK = 65536

View File

@ -31,6 +31,7 @@ import logging
from PIL import Image, ImageFile, ImagePalette, _binary
logger = logging.getLogger(__name__)
logger.addHandler(logging.NullHandler())
i8 = _binary.i8
i16 = _binary.i16le

View File

@ -42,6 +42,7 @@ from PIL import Image, ImageFile, ImagePalette, _binary
__version__ = "0.9"
logger = logging.getLogger(__name__)
logger.addHandler(logging.NullHandler())
i8 = _binary.i8
i16 = _binary.i16be

View File

@ -29,6 +29,7 @@ from cffi import FFI
logger = logging.getLogger(__name__)
logger.addHandler(logging.NullHandler())
defs = """

View File

@ -10,6 +10,7 @@ import os
from PIL import Image, TiffImagePlugin
logger = logging.getLogger(__name__)
logger.addHandler(logging.NullHandler())
class LibTiffTestCase(PillowTestCase):

View File

@ -7,6 +7,7 @@ from helper import unittest, PillowTestCase, hopper, py3
from PIL import Image, TiffImagePlugin
logger = logging.getLogger(__name__)
logger.addHandler(logging.NullHandler())
class TestFileTiff(PillowTestCase):