[英]ModuleNotFoundError although package has been installed correctly
I'm getting ModuleNotFoundError: No module named 'macrobond_api_constants'
although the package seems to be installed correctly.我收到
ModuleNotFoundError: No module named 'macrobond_api_constants'
尽管软件包似乎安装正确。 I checked using conda list
command.我使用
conda list
命令进行了检查。
https://pypi.org/project/macrobond-api-constants/ https://pypi.org/project/macrobond-api-constants/
The instruction says this should be imported using import macrobond_api_constants
指令说这应该使用
import macrobond_api_constants
I tried to import using both Spyder
and PyCharm
.我尝试使用
Spyder
和PyCharm
进行导入。 Any idea how to fix this?知道如何解决这个问题吗?
In pycharm import libraries exist in different way.在 pycharm 中,导入库以不同的方式存在。 You can try this
你可以试试这个
1. Open PyCharm . 1.打开PyCharm 。
2. go to File -> settings -> Project:test(test means your project name) -> select project interpretor -> click add button
2.转到
File -> settings -> Project:test(test means your project name) -> select project interpretor -> click add button
3. after clicking add button and search the library which you want to install then install it. 3.点击添加按钮后,搜索您要安装的库然后安装它。
finally run the program.最后运行程序。
Thank you everyone that wanted to help me with this issue.感谢所有想帮助我解决这个问题的人。 I contacted lib authors (Macrobond) saying I cannot access library and turns out there was something that they messed.
我联系了库作者(Macrobond)说我无法访问库,结果发现他们搞砸了。 An update has been just released couple days ago.
几天前刚刚发布了更新。 Library is now accessible and works pretty well.
图书馆现在可以访问并且运行良好。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.