New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Virtualenv cannot copy the built-in library #2032
Comments
I read an article,when he creates it, he copies the.py file to lib,How do that? |
It copied only part of the built-in packages, and that was for python 2 only.
That's by design. You'll probably need to expand more on how you want to use it and why. |
Could not find platform independent libraries <prefix>
Could not find platform dependent libraries <exec_prefix>
Consider setting $PYTHONHOME to <prefix>[:<exec_prefix>]
Python path configuration:
PYTHONHOME = (not set)
PYTHONPATH = (not set)
program name = './python3'
isolated = 0
environment = 1
user site = 1
import site = 1
sys._base_executable = '/opt/env_test/bin/python3'
sys.base_prefix = '/opt/python381'
sys.base_exec_prefix = '/opt/python381'
sys.executable = '/opt/env_test/bin/python3'
sys.prefix = '/opt/python381'
sys.exec_prefix = '/opt/python381'
sys.path = [
'/opt/python381/lib/python38.zip',
'/opt/python381/lib/python3.8',
'/opt/python381/lib/lib-dynload',
]
Fatal Python error: init_fs_encoding: failed to get the Python codec of the filesystem encoding <
Python runtime state: core initialized \n
ModuleNotFoundError: No module named 'encodings' Now there's a problem. |
I know I probably shouldn't be asking questions here, but I really don't know where to go, so I'm sorry. |
Please provide a detailed step-by-step guide on how you got there. Ideally a docker image. |
|
virtual environments are references to the global pythons, and not meant to live on their own. They are not meant to be copied to another machine. And they will not work unless you also copy the global python and create the virtual environment in copy mode. See https://www.youtube.com/watch?v=o1Vue9CWRxU |
Thx,video solved my problem. |
Issue
I created a virtual environment,the /lib/ Python directory has no built-in libraries (only site-Package).
Because I'm going to use it.
Environment
python:3.8.1
Provide at least:
pip list
of the host python wherevirtualenv
is installed:Output of the virtual environment creation
Make sure to run the creation with
-vvv --with-traceback
:The text was updated successfully, but these errors were encountered: