fix: venv改为懒加载,兼容嵌入式CPython无venv模块
This commit is contained in:
@@ -4,9 +4,16 @@
|
||||
import logging
|
||||
import asyncio
|
||||
import sys
|
||||
import os as _os
|
||||
import signal
|
||||
import time
|
||||
import argparse
|
||||
|
||||
# 确保项目根目录在 sys.path 中 (嵌入式 CPython / PyPy 需要)
|
||||
_sys_path_root = _os.path.dirname(_os.path.abspath(__file__))
|
||||
if _sys_path_root not in sys.path:
|
||||
sys.path.insert(0, _sys_path_root)
|
||||
|
||||
from services.project_engine import ProjectEngine
|
||||
from services.pyenv_manager import PyEnvManager
|
||||
from services.proxy_service import ProxyService
|
||||
|
||||
Reference in New Issue
Block a user