mirror of
https://github.com/python/cpython.git
synced 2025-08-03 16:39:00 +00:00
[3.11] gh-113421: Fix multiprocessing logger for "%(filename)s" (GH-113423) (GH-113451)
(cherry picked from commit ce77ee5035
)
Co-authored-by: Xu Song <xusong.vip@gmail.com>
This commit is contained in:
parent
336d445934
commit
d04ca4ccd7
3 changed files with 28 additions and 4 deletions
|
@ -43,19 +43,19 @@ _log_to_stderr = False
|
|||
|
||||
def sub_debug(msg, *args):
|
||||
if _logger:
|
||||
_logger.log(SUBDEBUG, msg, *args)
|
||||
_logger.log(SUBDEBUG, msg, *args, stacklevel=2)
|
||||
|
||||
def debug(msg, *args):
|
||||
if _logger:
|
||||
_logger.log(DEBUG, msg, *args)
|
||||
_logger.log(DEBUG, msg, *args, stacklevel=2)
|
||||
|
||||
def info(msg, *args):
|
||||
if _logger:
|
||||
_logger.log(INFO, msg, *args)
|
||||
_logger.log(INFO, msg, *args, stacklevel=2)
|
||||
|
||||
def sub_warning(msg, *args):
|
||||
if _logger:
|
||||
_logger.log(SUBWARNING, msg, *args)
|
||||
_logger.log(SUBWARNING, msg, *args, stacklevel=2)
|
||||
|
||||
def get_logger():
|
||||
'''
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue