赞
踩
添加以下文件,假如current_path在一级目录下
import os
import sys
current_path = os.path.abspath(__file__)
project_path = os.path.dirname(os.path.dirname(current_path))
sys.path.append(project_path)
另
import os
print(os.path.abspath("."))
print(os.getcwd())
Copyright © 2003-2013 www.wpsshop.cn 版权所有,并保留所有权利。