Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Removing spammy debug logging #1423

Merged
merged 2 commits into from
Sep 20, 2015
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion PIL/Image.py
Original file line number Diff line number Diff line change
Expand Up @@ -2309,7 +2309,10 @@ def _open_core(fp, filename, prefix):
_decompression_bomb_check(im.size)
return im
except (SyntaxError, IndexError, TypeError, struct.error):
logger.debug("", exc_info=True)
# Leave disabled by default, spams the logs with image
# opening failures that are entirely expected.
#logger.debug("", exc_info=True)
continue
return None

im = _open_core(fp, filename, prefix)
Expand Down
5 changes: 3 additions & 2 deletions PIL/PyAccess.py
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,9 @@ def __init__(self, img, readonly=False):
self.xsize = vals['xsize']
self.ysize = vals['ysize']

logger.debug("%s", vals)
# Debugging is polluting test traces, only useful here
# when hacking on PyAccess
#logger.debug("%s", vals)
self._post_init()

def _post_init(self):
Expand Down Expand Up @@ -310,7 +312,6 @@ def new(img, readonly=False):
if not access_type:
logger.debug("PyAccess Not Implemented: %s", img.mode)
return None
logger.debug("New PyAccess: %s", img.mode)
return access_type(img, readonly)

# End of file