File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1818import shutil
1919import subprocess
2020import sys
21+ import tempfile
2122import zipfile
2223from pathlib import Path
2324from typing import Dict
2425
26+ # auditwheel 6.3.0's InWheel uses tempfile.TemporaryDirectory for its bdist_dir,
27+ # but its rewrite_record helper walks files via Path.resolve(strict=True). On
28+ # macOS (and any system whose tempdir traverses a symlink, e.g. /var ->
29+ # /private/var) the walked paths don't share a prefix with bdist_dir, causing
30+ # Path.relative_to() to fail. Resolve the tempdir up front so both sides match.
31+ tempfile .tempdir = str (Path (tempfile .gettempdir ()).resolve ())
32+
2533driver_version = "1.59.1"
2634
2735base_wheel_bundles = [
@@ -177,10 +185,7 @@ def _build_wheel(
177185 if InWheel :
178186 wheelhouse_whl = os .path .join ("wheelhouse" , os .path .basename (whlfile ))
179187 shutil .move (whlfile , wheelhouse_whl )
180- with InWheel (
181- in_wheel = Path (wheelhouse_whl ).resolve (),
182- out_wheel = Path (whlfile ).resolve (),
183- ):
188+ with InWheel (in_wheel = Path (wheelhouse_whl ), out_wheel = Path (whlfile )):
184189 print (f"Updating RECORD file of { whlfile } " )
185190 print ("Copying new wheels" )
186191 shutil .rmtree ("wheelhouse" )
You can’t perform that action at this time.
0 commit comments