feat(repo): added help formatters for version numbers to cogs that have them and migrated to using red's inbuilt loggers instead of logging.getLogger
This commit is contained in:
parent
ae31a61436
commit
178a92559c
6 changed files with 62 additions and 30 deletions
|
@ -1,14 +1,4 @@
|
|||
import logging
|
||||
from red_commons.logging import getLogger
|
||||
|
||||
logger = logging.getLogger('red.seacogs.pterodactyl')
|
||||
class WebsocketLogger(logging.Logger):
|
||||
def __init__(self, name, level=logging.NOTSET):
|
||||
super().__init__(name, level)
|
||||
|
||||
def debug(self, msg, *args, **kwargs):
|
||||
self.log(logging.VERBOSE, msg, *args, **kwargs)
|
||||
|
||||
logging.setLoggerClass(WebsocketLogger)
|
||||
websocket_logger = logging.getLogger('red.seacogs.pterodactyl.websocket')
|
||||
logging.VERBOSE = 5
|
||||
logging.addLevelName(logging.VERBOSE, "VERBOSE")
|
||||
logger = getLogger('red.seacogs.pterodactyl')
|
||||
websocket_logger = getLogger('red.seacogs.pterodactyl.websocket')
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue