-
Notifications
You must be signed in to change notification settings - Fork 0
/
logging.conf
69 lines (53 loc) · 1.25 KB
/
logging.conf
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
###########
# loggers #
###########
[loggers]
keys=root,main,wallpaper_downloader,database,email
[logger_root]
level=DEBUG
handlers=consoleHandler
[logger_main]
level=DEBUG
handlers=fileHandler
qualname=main
[logger_wallpaper_downloader]
level=DEBUG
handlers=fileHandler
qualname=wallpaper_downloader
[logger_database]
level=DEBUG
handlers=fileHandler
qualname=utils.database
[logger_email]
level=DEBUG
handlers=fileHandler
qualname=utils.email
############
# handlers #
############
[handlers]
keys=consoleHandler,fileHandler
[handler_consoleHandler]
class=StreamHandler
args=(sys.stdout,)
level=DEBUG
formatter=consoleFormatter
[handler_fileHandler]
class=logging.handlers.RotatingFileHandler
args=('./dlbingwallpaper.log', 'a', 1024*1024*10, 3, 'utf-8')
level=DEBUG
formatter=fileDebugFormatter
##############
# formatters #
##############
[formatters]
keys=consoleFormatter,fileDebugFormatter,fileFormatter
[formatter_consoleFormatter]
format=%(asctime)s[%(levelname)s]%(filename)s(%(lineno)d): %(message)s
datefmt=%Y-%m-%d %H:%M:%S
[formatter_fileDebugFormatter]
format=%(asctime)s[%(levelname)s]%(filename)s(%(lineno)d): %(message)s
datefmt=%Y-%m-%d %H:%M:%S
[formatter_fileFormatter]
format=%(asctime)s[%(levelname)s]: %(message)s
datefmt=%Y-%m-%d %H:%M:%S