From 852bb4f08aa3fc5cc63e7307576b0ce02297536b Mon Sep 17 00:00:00 2001 From: wunder957 Date: Sat, 9 Sep 2023 13:18:06 +0800 Subject: [PATCH] Compatible with python 3.8 --- duetector/filters/pattern.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/duetector/filters/pattern.py b/duetector/filters/pattern.py index 1e990b4..4823dfb 100644 --- a/duetector/filters/pattern.py +++ b/duetector/filters/pattern.py @@ -1,7 +1,7 @@ import os import re from ast import literal_eval -from typing import List, NamedTuple, Optional, Union +from typing import List, NamedTuple, Optional, Set, Union from duetector.extension.filter import hookimpl from duetector.filters import Filter @@ -78,7 +78,7 @@ def enable_customize_exclude(self) -> bool: return bool(self.config.enable_customize_exclude) @staticmethod - def _wrap_exclude_list(value: Union[str, List[str]]) -> set[str]: + def _wrap_exclude_list(value: Union[str, List[str]]) -> Set[str]: """ Wrap exclude list to list if it's not a list """