From 2f4449f080f48ed5109e65b904563ab9242fd6b1 Mon Sep 17 00:00:00 2001 From: Zhipeng Xue <543984341@qq.com> Date: Wed, 10 Jul 2024 16:10:54 +0800 Subject: [PATCH] Type hints Fix --- errbot/cli.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/errbot/cli.py b/errbot/cli.py index 61934501a..745fd114c 100755 --- a/errbot/cli.py +++ b/errbot/cli.py @@ -23,6 +23,7 @@ from pathlib import Path from platform import system from typing import Optional, Union +from collections.abc import Mapping from errbot.bootstrap import CORE_BACKENDS from errbot.logs import root_logger @@ -82,8 +83,7 @@ def get_config(config_path: str): exit(-1) -def _read_dict() -> dict: - from collections.abc import Mapping +def _read_dict() -> Mapping: new_dict = ast.literal_eval(sys.stdin.read()) if not isinstance(new_dict, Mapping):