Get wheel RECORD directly from wheel file

This reduces our dependence on disk files, and removes some complexity
around Python 2/3 compatibility with the csv module.
This commit is contained in:
Chris Hunt 2020-07-03 20:49:16 -04:00
parent 231211a7ab
commit d441f9518b
1 changed files with 3 additions and 2 deletions

View File

@ -644,10 +644,11 @@ def install_unpacked_wheel(
pass
generated.append(requested_path)
record_text = distribution.get_metadata('RECORD')
record_rows = list(csv.reader(record_text.splitlines()))
# Record details of all files installed
record_path = os.path.join(dest_info_dir, 'RECORD')
with open(record_path, **csv_io_kwargs('r')) as record_file:
record_rows = list(csv.reader(record_file))
rows = get_csv_rows_for_installed(
record_rows,