mirror of
https://github.com/microsoft/onefuzz.git
synced 2025-06-13 02:28:10 +00:00
Use consistent logger names (#1945)
This commit is contained in:
@ -46,7 +46,7 @@ DEFAULT_TOKEN_PATH = os.path.join(ONEFUZZ_BASE_PATH, "access_token.json")
|
||||
REQUEST_CONNECT_TIMEOUT = 30.0
|
||||
REQUEST_READ_TIMEOUT = 120.0
|
||||
|
||||
LOGGER = logging.getLogger("nsv-backend")
|
||||
LOGGER = logging.getLogger("backend")
|
||||
|
||||
|
||||
@contextlib.contextmanager
|
||||
|
@ -558,11 +558,11 @@ def execute_api(api: Any, api_types: List[Any], version: str) -> int:
|
||||
elif args.verbose == 1:
|
||||
logging.basicConfig(level=logging.WARNING)
|
||||
api.logger.setLevel(logging.INFO)
|
||||
logging.getLogger("nsv-backend").setLevel(logging.DEBUG)
|
||||
logging.getLogger("backend").setLevel(logging.DEBUG)
|
||||
elif args.verbose == 2:
|
||||
logging.basicConfig(level=logging.INFO)
|
||||
api.logger.setLevel(logging.DEBUG)
|
||||
logging.getLogger("nsv-backend").setLevel(logging.DEBUG)
|
||||
logging.getLogger("backend").setLevel(logging.DEBUG)
|
||||
elif args.verbose >= 3:
|
||||
logging.basicConfig(level=logging.DEBUG)
|
||||
api.logger.setLevel(logging.DEBUG)
|
||||
|
@ -78,7 +78,7 @@ def build_ssh_command(
|
||||
if port:
|
||||
cmd += ["-p", str(port)]
|
||||
|
||||
log_level = logging.getLogger("nsv-backend").getEffectiveLevel()
|
||||
log_level = logging.getLogger("backend").getEffectiveLevel()
|
||||
if log_level <= logging.DEBUG:
|
||||
cmd += ["-v"]
|
||||
|
||||
|
Reference in New Issue
Block a user