问题遇到的现象和发生背景
已经安装成功了tushare,但是还是出现了No module named 'tushare'
问题相关代码,请勿粘贴截图
import tushare as ts
ts.version
运行结果及报错内容
ModuleNotFoundError Traceback (most recent call last)
~\AppData\Local\Temp/ipykernel_15612/2502883367.py in <module>
----> 1 import tushare as ts
2 ts._version_
ModuleNotFoundError: No module named 'tushare'
我的解答思路和尝试过的方法
重新安装tushare,出现
D:>pip install tushare
Requirement already satisfied: tushare in d:\lib\site-packages (1.2.78)
Requirement already satisfied: pandas in d:\lib\site-packages (from tushare) (1.3.5)
Requirement already satisfied: simplejson in d:\lib\site-packages (from tushare) (3.17.6)
Requirement already satisfied: websocket-client>=0.57.0 in d:\lib\site-packages (from tushare) (1.2.3)
Requirement already satisfied: requests in d:\lib\site-packages (from tushare) (2.26.0)
Requirement already satisfied: lxml in d:\lib\site-packages (from tushare) (4.7.1)
Requirement already satisfied: bs4 in d:\lib\site-packages (from tushare) (0.0.1)
Requirement already satisfied: beautifulsoup4 in d:\lib\site-packages (from bs4->tushare) (4.10.0)
Requirement already satisfied: pytz>=2017.3 in d:\lib\site-packages (from pandas->tushare) (2021.3)
Requirement already satisfied: python-dateutil>=2.7.3 in d:\lib\site-packages (from pandas->tushare) (2.8.2)
Requirement already satisfied: numpy>=1.21.0 in d:\lib\site-packages (from pandas->tushare) (1.21.5)
Requirement already satisfied: idna<4,>=2.5 in d:\lib\site-packages (from requests->tushare) (3.3)
Requirement already satisfied: urllib3<1.27,>=1.21.1 in d:\lib\site-packages (from requests->tushare) (1.26.7)
Requirement already satisfied: charset-normalizer~=2.0.0 in d:\lib\site-packages (from requests->tushare) (2.0.9)
Requirement already satisfied: certifi>=2017.4.17 in d:\lib\site-packages (from requests->tushare) (2021.10.8)
Requirement already satisfied: six>=1.5 in d:\lib\site-packages (from python-dateutil>=2.7.3->pandas->tushare) (1.16.0)
Requirement already satisfied: soupsieve>1.2 in d:\lib\site-packages (from beautifulsoup4->bs4->tushare) (2.3.1)
我想要达到的结果
应该怎么办啊