Skip to content

Commit c8d2385

Browse files
ttm56pmxschmitt
authored andcommitted
cherry-pick(#2671): devops: fix build process producing wheels with incorrect RECORD
1 parent ebf26a6 commit c8d2385

File tree

1 file changed

+4
-5
lines changed

1 file changed

+4
-5
lines changed

Diff for: setup.py

+4-5
Original file line numberDiff line numberDiff line change
@@ -165,13 +165,12 @@ def _build_wheel(
165165
for whlfile in glob.glob(os.path.join(self.dist_dir, "*.whl")):
166166
os.makedirs("wheelhouse", exist_ok=True)
167167
if InWheel:
168-
with InWheel(
169-
in_wheel=whlfile,
170-
out_wheel=os.path.join("wheelhouse", os.path.basename(whlfile)),
171-
):
168+
wheelhouse_whl = os.path.join("wheelhouse", os.path.basename(whlfile))
169+
shutil.move(whlfile, wheelhouse_whl)
170+
with InWheel(in_wheel=wheelhouse_whl, out_wheel=whlfile):
172171
print(f"Updating RECORD file of {whlfile}")
173172
print("Copying new wheels")
174-
shutil.move("wheelhouse", self.dist_dir)
173+
shutil.rmtree("wheelhouse")
175174

176175
def _download_and_extract_local_driver(
177176
self,

0 commit comments

Comments
 (0)