Automatically remove dist-info/REQUESTED files together with RECORD

This commit is contained in:
Lumir Balhar 2020-09-23 10:52:45 +02:00
parent 7cc563401d
commit efdfb4727f
3 changed files with 3 additions and 4 deletions

View File

@ -49,6 +49,7 @@ for site_dir in ${site_dirs[@]}; do
%{__python3} -B %{_rpmconfigdir}/redhat/pyproject_preprocess_record.py \\
--buildroot %{buildroot} --record ${distinfo}/RECORD --output %{pyproject_record}
rm ${distinfo}/RECORD
rm ${distinfo}/REQUESTED || :
done
done
lines=$(wc -l %{pyproject_ghost_distinfo} | cut -f1 -d" ")

View File

@ -145,8 +145,8 @@ def classify_paths(
continue
if path.parent == distinfo:
if path.name == "RECORD":
# RECORD files are removed manually in %pyproject_install
if path.name in ("RECORD", "REQUESTED"):
# RECORD and REQUESTED files are removed in %pyproject_install
# See PEP 627
continue
# TODO is this a license/documentation?

View File

@ -1410,7 +1410,6 @@ classified:
- /usr/lib/python3.7/site-packages/Printrun-2.0.0rc6.dist-info/INSTALLER
- /usr/lib/python3.7/site-packages/Printrun-2.0.0rc6.dist-info/METADATA
- /usr/lib/python3.7/site-packages/Printrun-2.0.0rc6.dist-info/top_level.txt
- /usr/lib/python3.7/site-packages/Printrun-2.0.0rc6.dist-info/REQUESTED
- /usr/lib/python3.7/site-packages/Printrun-2.0.0rc6.dist-info/WHEEL
- /usr/lib/python3.7/site-packages/Printrun-2.0.0rc6.dist-info/direct_url.json
licenses: []
@ -2711,7 +2710,6 @@ dumped:
- /usr/lib/python3.7/site-packages/Printrun-2.0.0rc6.dist-info/COPYING
- /usr/lib/python3.7/site-packages/Printrun-2.0.0rc6.dist-info/INSTALLER
- /usr/lib/python3.7/site-packages/Printrun-2.0.0rc6.dist-info/METADATA
- /usr/lib/python3.7/site-packages/Printrun-2.0.0rc6.dist-info/REQUESTED
- /usr/lib/python3.7/site-packages/Printrun-2.0.0rc6.dist-info/WHEEL
- /usr/lib/python3.7/site-packages/Printrun-2.0.0rc6.dist-info/direct_url.json
- /usr/lib/python3.7/site-packages/Printrun-2.0.0rc6.dist-info/top_level.txt