summaryrefslogtreecommitdiff
path: root/Python/errors.c
diff options
context:
space:
mode:
authorJason Wilkes <notarealdeveloper@gmail.com>2022-02-07 17:09:07 -0800
committerGitHub <noreply@github.com>2022-02-07 17:09:07 -0800
commitda576e08296490e94924421af71001bcfbccb317 (patch)
treee6967cb02a5a5b512c0cd1e2a4e45a49e85744ad /Python/errors.c
parent7a0486eaa98083e0407ff491872db6d7a0da2635 (diff)
downloadcpython-git-da576e08296490e94924421af71001bcfbccb317.tar.gz
bpo-46678: Fix Invalid cross device link in Lib/test/support/import_helper.py (GH-31204)
In [Lib/test/support/import_helper.py](https://github.com/python/cpython/blob/master/Lib/test/support/import_helper.py), the function `make_legacy_pyc` makes a call to `os.rename` which can fail when the source and target live on different devices. This happens (for example) when `PYTHONPYCACHEPREFIX` is set to a directory anywhere on disk, while a ramdisk is mounted on `/tmp` (the latter of which is the default on various Linux distros). Replacing `os.rename` with `shutil.move` fixes this. Automerge-Triggered-By: GH:brettcannon
Diffstat (limited to 'Python/errors.c')
0 files changed, 0 insertions, 0 deletions