Author: Matti Picus <[email protected]>
Branch: py3.6
Changeset: r98588:39898aeb2799
Date: 2020-01-26 12:12 +0200
http://bitbucket.org/pypy/pypy/changeset/39898aeb2799/
Log: issue 3159: venv should copy directories, not just files
diff --git a/lib-python/3/venv/__init__.py b/lib-python/3/venv/__init__.py
--- a/lib-python/3/venv/__init__.py
+++ b/lib-python/3/venv/__init__.py
@@ -196,7 +196,10 @@
logger.warning('Unable to symlink %r to %r', src, dst)
force_copy = True
if force_copy:
- shutil.copyfile(src, dst)
+ if os.path.isdir(src):
+ shutil.copytree(src, dst)
+ else:
+ shutil.copyfile(src, dst)
def setup_python(self, context):
"""
_______________________________________________
pypy-commit mailing list
[email protected]
https://mail.python.org/mailman/listinfo/pypy-commit