@@ -42,26 +42,21 @@ def find_missing_reqs(
42
42
]
43
43
44
44
for package in search_packages_info (all_pkgs ):
45
- if isinstance (package , dict ): # pragma: no cover
46
- package_name = package ["name" ]
47
- package_location = package ["location" ]
48
- package_files = package .get ("files" , []) or []
49
- else : # pragma: no cover
50
- package_name = package .name
51
- package_location = package .location
52
- package_files = []
53
- for item in package .files or []:
54
- here = pathlib .Path ("." ).resolve ()
55
- item_location_rel = pathlib .Path (package_location ) / item
56
- item_location = item_location_rel .resolve ()
57
- try :
58
- relative_item_location = item_location .relative_to (here )
59
- except ValueError :
60
- # Ideally we would use Pathlib.is_relative_to rather than
61
- # checking for a ValueError, but that is only available in
62
- # Python 3.9+.
63
- relative_item_location = item_location
64
- package_files .append (str (relative_item_location ))
45
+ package_name = package .name
46
+ package_location = package .location
47
+ package_files = []
48
+ for item in package .files or []:
49
+ here = pathlib .Path ("." ).resolve ()
50
+ item_location_rel = pathlib .Path (package_location ) / item
51
+ item_location = item_location_rel .resolve ()
52
+ try :
53
+ relative_item_location = item_location .relative_to (here )
54
+ except ValueError :
55
+ # Ideally we would use Pathlib.is_relative_to rather than
56
+ # checking for a ValueError, but that is only available in
57
+ # Python 3.9+.
58
+ relative_item_location = item_location
59
+ package_files .append (str (relative_item_location ))
65
60
66
61
log .debug (
67
62
"installed package: %s (at %s)" , package_name , package_location
0 commit comments