Type annot name in put to log routine

incremental_update_paths
Tyler Goodlet 2022-05-21 11:45:16 -04:00
parent f5de361f49
commit c256d3bdc0
1 changed files with 5 additions and 2 deletions

View File

@ -25,10 +25,13 @@ from pygments import highlight, lexers, formatters
# Makes it so we only see the full module name when using ``__name__`` # Makes it so we only see the full module name when using ``__name__``
# without the extra "piker." prefix. # without the extra "piker." prefix.
_proj_name = 'piker' _proj_name: str = 'piker'
def get_logger(name: str = None) -> logging.Logger: def get_logger(
name: str = None,
) -> logging.Logger:
'''Return the package log or a sub-log for `name` if provided. '''Return the package log or a sub-log for `name` if provided.
''' '''
return tractor.log.get_logger(name=name, _root_name=_proj_name) return tractor.log.get_logger(name=name, _root_name=_proj_name)