File tree 2 files changed +7
-6
lines changed
2 files changed +7
-6
lines changed Original file line number Diff line number Diff line change 8
8
from collections import defaultdict
9
9
from itertools import chain , filterfalse
10
10
from pathlib import Path
11
+ from typing import DefaultDict
11
12
12
13
from ._supported_packages import PACKAGE_RENAMES , PYODIDE_PACKAGES , STANDARD_LIBRARY
13
14
@@ -65,9 +66,9 @@ def __repr__(self) -> str:
65
66
66
67
class FinderResult :
67
68
def __init__ (self ) -> None :
68
- self ._packages = set ()
69
- self ._locals = set ()
70
- self ._unsupported = defaultdict (set )
69
+ self ._packages : set [ str ] = set ()
70
+ self ._locals : set [ str ] = set ()
71
+ self ._unsupported : DefaultDict [ str , set ] = defaultdict (set )
71
72
72
73
def add_package (self , pkg_name : str ) -> None :
73
74
self ._packages .add (pkg_name )
Original file line number Diff line number Diff line change @@ -25,9 +25,9 @@ class Dependency:
25
25
This class is a general abstraction over both external and local module dependency."""
26
26
27
27
import_line : str # Import line to inject in code under test
28
- filename : str = None # filename: to be used for tmp local modules, i.e. paths
29
- code : str = None # code in the tmp local modules
30
- inject : str = None # any code to inject in code under test
28
+ filename : str | None = None # filename: to be used for tmp local modules, i.e. paths
29
+ code : str | None = None # code in the tmp local modules
30
+ inject : str | None = None # any code to inject in code under test
31
31
32
32
33
33
@pytest .fixture ()
You can’t perform that action at this time.
0 commit comments