This commit is contained in:
Your Name
2026-04-11 14:02:09 +02:00
parent 2e3b2ae7e0
commit 35537a3bc4
7 changed files with 175 additions and 66 deletions
-5
View File
@@ -8,11 +8,6 @@ import sys
import sysconfig
from pathlib import Path
if sys.prefix != sys.base_prefix:
# In venv, re-exec to the base executable
interpreter_path = os.path.realpath(sys.executable)
os.execv(interpreter_path, [interpreter_path, __file__, *sys.argv[1:]])
libpath = Path(sysconfig.get_path("purelib")).relative_to(sysconfig.get_config_var("base"))
new_path = (Path(__file__) / "../.." / libpath).resolve()
assert new_path.is_dir()