Island: Fix type hint in cc/server_utils/island_logger.py

This commit is contained in:
Shreya Malviya 2022-08-02 12:28:24 +05:30
parent 29646ecf43
commit 96bae42388
1 changed files with 1 additions and 2 deletions

View File

@ -2,7 +2,6 @@ import logging
import logging.handlers import logging.handlers
import sys import sys
from pathlib import Path from pathlib import Path
from typing import Mapping
ISLAND_LOG_FILENAME = "monkey_island.log" ISLAND_LOG_FILENAME = "monkey_island.log"
LOG_FORMAT = "%(asctime)s - %(levelname)s - %(filename)s:%(lineno)s - %(funcName)s() - %(message)s" LOG_FORMAT = "%(asctime)s - %(levelname)s - %(filename)s:%(lineno)s - %(funcName)s() - %(message)s"
@ -34,7 +33,7 @@ def get_log_file_path(data_dir: Path) -> Path:
return data_dir / ISLAND_LOG_FILENAME return data_dir / ISLAND_LOG_FILENAME
def get_log_file_contents(log_file_path: Path) -> Mapping: def get_log_file_contents(log_file_path: Path) -> str:
with open(log_file_path, "rt") as f: with open(log_file_path, "rt") as f:
log_file = f.read() log_file = f.read()
return log_file return log_file