Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(1)

Side by Side Diff: Lib/logging/__init__.py

Issue 10639: reindent.py converts newlines to platform default
Patch Set: Created 8 years, 8 months ago
Left:
Right:
Use n/p to move between diff chunks; N/P to move between comments. Please Sign in to add in-line comments.
Jump to:
View unified diff | Download patch
« no previous file with comments | « Lib/logging/handlers.py ('k') | Lib/multiprocessing/connection.py » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 # Copyright 2001-2011 by Vinay Sajip. All Rights Reserved. 1 # Copyright 2001-2011 by Vinay Sajip. All Rights Reserved.
2 # 2 #
3 # Permission to use, copy, modify, and distribute this software and its 3 # Permission to use, copy, modify, and distribute this software and its
4 # documentation for any purpose and without fee is hereby granted, 4 # documentation for any purpose and without fee is hereby granted,
5 # provided that the above copyright notice appear in all copies and that 5 # provided that the above copyright notice appear in all copies and that
6 # both that copyright notice and this permission notice appear in 6 # both that copyright notice and this permission notice appear in
7 # supporting documentation, and that the name of Vinay Sajip 7 # supporting documentation, and that the name of Vinay Sajip
8 # not be used in advertising or publicity pertaining to distribution 8 # not be used in advertising or publicity pertaining to distribution
9 # of the software without specific, written prior permission. 9 # of the software without specific, written prior permission.
10 # VINAY SAJIP DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING 10 # VINAY SAJIP DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING
(...skipping 1424 matching lines...) Expand 10 before | Expand all | Expand 10 after
1435 for hdlr in c.handlers: 1435 for hdlr in c.handlers:
1436 found = found + 1 1436 found = found + 1
1437 if record.levelno >= hdlr.level: 1437 if record.levelno >= hdlr.level:
1438 hdlr.handle(record) 1438 hdlr.handle(record)
1439 if not c.propagate: 1439 if not c.propagate:
1440 c = None #break out 1440 c = None #break out
1441 else: 1441 else:
1442 c = c.parent 1442 c = c.parent
1443 if (found == 0): 1443 if (found == 0):
1444 if lastResort: 1444 if lastResort:
1445 if record.levelno >= lastResort.level: 1445 lastResort.handle(record)
1446 lastResort.handle(record)
1447 elif raiseExceptions and not self.manager.emittedNoHandlerWarning: 1446 elif raiseExceptions and not self.manager.emittedNoHandlerWarning:
1448 sys.stderr.write("No handlers could be found for logger" 1447 sys.stderr.write("No handlers could be found for logger"
1449 " \"%s\"\n" % self.name) 1448 " \"%s\"\n" % self.name)
1450 self.manager.emittedNoHandlerWarning = True 1449 self.manager.emittedNoHandlerWarning = True
1451 1450
1452 def getEffectiveLevel(self): 1451 def getEffectiveLevel(self):
1453 """ 1452 """
1454 Get the effective level for this logger. 1453 Get the effective level for this logger.
1455 1454
1456 Loop through this logger and its parents in the logger hierarchy, 1455 Loop through this logger and its parents in the logger hierarchy,
(...skipping 434 matching lines...) Expand 10 before | Expand all | Expand 10 after
1891 """ 1890 """
1892 global _warnings_showwarning 1891 global _warnings_showwarning
1893 if capture: 1892 if capture:
1894 if _warnings_showwarning is None: 1893 if _warnings_showwarning is None:
1895 _warnings_showwarning = warnings.showwarning 1894 _warnings_showwarning = warnings.showwarning
1896 warnings.showwarning = _showwarning 1895 warnings.showwarning = _showwarning
1897 else: 1896 else:
1898 if _warnings_showwarning is not None: 1897 if _warnings_showwarning is not None:
1899 warnings.showwarning = _warnings_showwarning 1898 warnings.showwarning = _warnings_showwarning
1900 _warnings_showwarning = None 1899 _warnings_showwarning = None
OLDNEW
« no previous file with comments | « Lib/logging/handlers.py ('k') | Lib/multiprocessing/connection.py » ('j') | no next file with comments »

RSS Feeds Recent Issues | This issue
This is Rietveld 894c83f36cb7+