mirror of
https://github.com/Mikaela/Limnoria.git
synced 2025-01-10 20:22:36 +01:00
Changed minimumDebugPriority to minimumPriority (since it's set in the debug module now anyway).
This commit is contained in:
parent
898a4e2ef1
commit
da38a7b59b
@ -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
|
||||
|
@ -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))
|
||||
|
Loading…
Reference in New Issue
Block a user