on-internet
← Community

Vim 9.1 and Python virtual environments

Stack Overflow ·

My Vim scripts use Vim's embedded Python environment. One of these requires the Python environment to use a virtual environment. Ideally Vim would inherit the virtual environment settings from the shell that launched it. Vim uses its own embedded Python interpreter. Some of the environment variables from the parent process, for example VIRTUAL_ENV, are set correctly. But Python's sys.path isn't honoring the virtual environment settings. How do Vim's pythonthreedll and pythonthreehome options affect this behavior? From Vim's help: 'pythonthreedll' Specifies the name of the Python 3 shared libra

Comments

Sign in or sign up to comment and upvote.

No comments yet.