File size: 500 Bytes
78b07ad
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
import logging
from logging.handlers import RotatingFileHandler

logging.basicConfig(
    format="[%(asctime)s]:[%(name)s]:[%(levelname)s] - %(message)s",
    level=logging.INFO,
    datefmt="%H:%M:%S",
    handlers=[
        RotatingFileHandler(
            "HellBot.log", maxBytes=(1024 * 1024 * 5), backupCount=10, encoding="utf-8"
        ),
        logging.StreamHandler(),
    ],
)


logging.getLogger("pyrogram").setLevel(logging.ERROR)

LOGS = logging.getLogger("HellBot")