執行python文件找不到導入的模塊問題

1、問題復現: 2、解決方案 添加如下代碼: import sys from os.path import abspath,dirname sys.path.insert(0,dirname(dirname(abspath(__file__)))) 3、原因分析: 不知道啊,歡迎大神留言
相關文章
相關標籤/搜索