File: log.py

package info (click to toggle)
python-aio-pika 9.5.6-1
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 1,428 kB
  • sloc: python: 8,009; makefile: 36; xml: 1
file content (11 lines) | stat: -rw-r--r-- 246 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
import logging


logger: logging.Logger = logging.getLogger("aio_pika")


def get_logger(name: str) -> logging.Logger:
    package, module = name.split(".", 1)
    if package == logger.name:
        name = module
    return logger.getChild(name)