Changed minimumDebugPriority to minimumPriority (since it's set in the debug module now anyway).

This commit is contained in:
Jeremy Fincher 2003-10-02 04:54:25 +00:00
parent 898a4e2ef1
commit da38a7b59b
2 changed files with 7 additions and 7 deletions

View File

@ -17,7 +17,7 @@ import debug
import utils
import ircutils
debug.minimumDebugPriority = 'high'
debug.minimumPriority = 'high'
useColor = False
@ -469,7 +469,7 @@ if __name__ == '__main__':
if yn('Would you like to turn this colorization off?') == 'y':
debugVariables['colorterm'] = False
# debug.minimumDebugPriority
# debug.minimumPriority
myPrint("""Your bot can handle debug messages at four priorities, 'high,'
'normal,' 'low,' and 'verbose,' in decreasing order of priority. By
default, your bot will log all of these priorities. You can, however,
@ -484,7 +484,7 @@ if __name__ == '__main__':
priority = anything('What would you like the minimum priority to be? '
'Just press enter to accept the default.')
if priority:
debugVariables['minimumDebugPriority'] = priority
debugVariables['minimumPriority'] = priority
if advanced:
myPrint("""Here's some stuff you only get to choose if you're an

View File

@ -75,9 +75,9 @@ else:
# printf: True if printf debugging messages should be printed.
printf = False
# minimumDebugPriority: Lowest priority logged;
# One of {'verbose', 'low', 'normal', 'high'}.
minimumDebugPriority = 'verbose'
# minimumPriority: Lowest priority logged;
# One of {'verbose', 'low', 'normal', 'high'}.
minimumPriority = 'verbose'
# deadlyExceptions: Exceptions that should cause immediate failure.
deadlyExceptions = [KeyboardInterrupt, SystemExit]
@ -197,7 +197,7 @@ def unrecoverableException():
exit(-1)
def msg(s, priority='low'):
if priorities[priority] >= priorities[minimumDebugPriority]:
if priorities[priority] >= priorities[minimumPriority]:
if stderr:
if colorterm:
sys.stderr.write(priorityColors.get(priority))