parameters: (logger_name)
return_statement: return logger_name
docstring: Modify logger name.
docstring_summary: Modify logger name.
docstring_tokens: Modify logger name .
function: def _shorten(logger_name):
      """Modify logger name."""
      # TODO: this function is only called for the fixture and fixture node loggers.
      #  If additional abbreviation is desired, we will need to call _shorten() in the appropriate places.
  
      removes = config.SHORTEN_LOGGER_NAME_CONFIG.get("remove", [])
      for remove in removes:
          logger_name = logger_name.replace(remove, "")
  
      replaces = config.SHORTEN_LOGGER_NAME_CONFIG.get("replace", {})
      for key, value in replaces.items():
          logger_name = logger_name.replace(key, value)
  
      # remove leading and trailing colons and underscores
      logger_name = re.sub(r"(^[:_]+|[:_]+$)", "", logger_name)
  
      return logger_name
function_tokens: def _shorten ( logger_name ) : # TODO: this function is only called for the fixture and fixture node loggers. #  If additional abbreviation is desired, we will need to call _shorten() in the appropriate places. removes = config . SHORTEN_LOGGER_NAME_CONFIG . get ( "remove" , [ ] ) for remove in removes : logger_name = logger_name . replace ( remove , "" ) replaces = config . SHORTEN_LOGGER_NAME_CONFIG . get ( "replace" , { } ) for key , value in replaces . items ( ) : logger_name = logger_name . replace ( key , value ) # remove leading and trailing colons and underscores logger_name = re . sub ( r"(^[:_]+|[:_]+$)" , "" , logger_name ) return logger_name