33import traceback
44from itertools import chain
55from tkinter import TclError , Tk
6- from typing import Dict , List , Tuple , Any , Optional , Iterable , Collection
7- from tkinter import TclError
8- from tkinter import Tk
9- from typing import Dict
10- from typing import List
6+ from typing import Any , Collection , Dict , Iterable , List , Optional , Tuple
117
128import requests
13- from colorama import Fore
14- from colorama import deinit
15- from colorama import init
9+ from colorama import Fore , deinit , init
1610
1711# Local imports
1812from enums .item_modifier_type import ItemModifierType
1913from models .item_modifier import ItemModifier
2014from utils .config import LEAGUE , PROJECT_URL , USE_GUI , USE_HOTKEYS
21- from utils .currency import (CATALYSTS , CURRENCY , DIV_CARDS , ESSENCES , FOSSILS ,
22- FRAGMENTS_AND_SETS , INCUBATORS , OILS , RESONATORS ,
23- SCARABS , VIALS )
24- from utils .config import LEAGUE
25- from utils .config import PROJECT_URL
26- from utils .config import USE_GUI
27- from utils .config import USE_HOTKEYS
28- from utils .currency import CATALYSTS
29- from utils .currency import CURRENCY
30- from utils .currency import DIV_CARDS
31- from utils .currency import ESSENCES
32- from utils .currency import FOSSILS
33- from utils .currency import FRAGMENTS_AND_SETS
34- from utils .currency import INCUBATORS
35- from utils .currency import OILS
36- from utils .currency import RESONATORS
37- from utils .currency import SCARABS
38- from utils .currency import VIALS
15+ from utils .currency import (
16+ CATALYSTS ,
17+ CURRENCY ,
18+ DIV_CARDS ,
19+ ESSENCES ,
20+ FOSSILS ,
21+ FRAGMENTS_AND_SETS ,
22+ INCUBATORS ,
23+ OILS ,
24+ RESONATORS ,
25+ SCARABS ,
26+ VIALS ,
27+ )
3928from utils .exceptions import InvalidAPIResponseException
40- from utils .trade import get_leagues , get_item_modifiers
29+ from utils .trade import get_item_modifiers , get_leagues
4130
4231DEBUG = False
4332
@@ -787,7 +776,6 @@ def get_mods_by_type(type: ItemModifierType) -> Iterable[ItemModifier]:
787776 if DEBUG :
788777 print ("AFFIX:" , affix )
789778
790-
791779 if re .search (r"\((pseudo|implicit|crafted)\)" , affix ):
792780 # Do these need to be searched in a specific order?
793781 search_order = [ItemModifierType .PSEUDO , ItemModifierType .IMPLICIT , ItemModifierType .CRAFTED ]
@@ -808,7 +796,7 @@ def get_mods_by_type(type: ItemModifierType) -> Iterable[ItemModifier]:
808796 if value is not None :
809797 return (enchant .id , value )
810798
811- raise NotImplementedError (' Unable to find matching affix.' )
799+ raise NotImplementedError (" Unable to find matching affix." )
812800
813801
814802def stat_translate (jaffix : str ) -> ItemModifier :
0 commit comments