4444
4545if sys .version_info [:3 ] < (3 , 7 , 2 ):
4646 # typing.Ordereddict not added until py 3.7.2
47- from collections import OrderedDict # type: ignore # until 3.6 dropped
48- OrderedDict_OMD = OrderedDict # type: ignore # until 3.6 dropped
47+ from collections import OrderedDict
48+ OrderedDict_OMD = OrderedDict
4949else :
50- from typing import OrderedDict # type: ignore # until 3.6 dropped
50+ from typing import OrderedDict
5151 OrderedDict_OMD = OrderedDict [str , List [T_OMD_value ]] # type: ignore[assignment, misc]
5252
5353# -------------------------------------------------------------
@@ -177,7 +177,7 @@ def __exit__(self, exception_type: str, exception_value: str, traceback: str) ->
177177class _OMD (OrderedDict_OMD ):
178178 """Ordered multi-dict."""
179179
180- def __setitem__ (self , key : str , value : _T ) -> None : # type: ignore[override]
180+ def __setitem__ (self , key : str , value : _T ) -> None :
181181 super (_OMD , self ).__setitem__ (key , [value ])
182182
183183 def add (self , key : str , value : Any ) -> None :
@@ -203,8 +203,8 @@ def setlast(self, key: str, value: Any) -> None:
203203 prior = super (_OMD , self ).__getitem__ (key )
204204 prior [- 1 ] = value
205205
206- def get (self , key : str , default : Union [_T , None ] = None ) -> Union [_T , None ]: # type: ignore
207- return super (_OMD , self ).get (key , [default ])[- 1 ] # type: ignore
206+ def get (self , key : str , default : Union [_T , None ] = None ) -> Union [_T , None ]:
207+ return super (_OMD , self ).get (key , [default ])[- 1 ]
208208
209209 def getall (self , key : str ) -> List [_T ]:
210210 return super (_OMD , self ).__getitem__ (key )
@@ -299,9 +299,9 @@ def __init__(self, file_or_files: Union[None, PathLike, 'BytesIO', Sequence[Unio
299299 :param repo: Reference to repository to use if [includeIf] sections are found in configuration files.
300300
301301 """
302- cp .RawConfigParser .__init__ (self , dict_type = _OMD ) # type: ignore[arg-type]
302+ cp .RawConfigParser .__init__ (self , dict_type = _OMD )
303303 self ._dict : Callable [..., _OMD ] # type: ignore[assignment] # mypy/typeshed bug
304- self ._defaults : _OMD # type: ignore[assignment] # mypy/typeshed bug
304+ self ._defaults : _OMD
305305 self ._sections : _OMD # type: ignore[assignment] # mypy/typeshed bug
306306
307307 # Used in python 3, needs to stay in sync with sections for underlying implementation to work
0 commit comments