Python 通过MPRester查询物料时出现I进程错误

Python 通过MPRester查询物料时出现I进程错误,python,python-3.x,pymatgen,iprogress,Python,Python 3.x,Pymatgen,Iprogress,我正在spyder3中使用python 3.8。我在执行以下操作时出错: mp=MPRester('api key') data = mp.query(criteria={}, properties=['task_id']) #this line raises error 错误是: NameError: name '**IProgress**' is not defined. 在处理上述异常期间,发生了另一个异常: ImportError: **FloatProgress** not fo

我正在
spyder3
中使用python 3.8。我在执行以下操作时出错:

mp=MPRester('api key')

data = mp.query(criteria={}, properties=['task_id']) #this line raises error
错误是:

NameError: name '**IProgress**' is not defined.
在处理上述异常期间,发生了另一个异常:

ImportError: **FloatProgress** not found. Please update jupyter and ipywidgets.

但是我没有使用Jupyter笔记本电脑,ipywidgets已经更新。在Google collab中工作时不会出现此问题

我不回答此错误,而是为我显示一个工作过的脚本。使用以下方法可能会有所帮助

从pymatgen导入MPRester
api=MPRester(“您的密钥”)
#你想要的标准
条件={“元素”:{“$all”:[“O”]},“元素”:{“$lt”:4}
#你想要的财产
属性=[“美丽的公式”、“到岸价”、“材料id”]
c=api.query(条件=条件,属性=属性)

我不是在回答错误,而是在为我展示一个工作过的脚本。使用以下方法可能会有所帮助

从pymatgen导入MPRester
api=MPRester(“您的密钥”)
#你想要的标准
条件={“元素”:{“$all”:[“O”]},“元素”:{“$lt”:4}
#你想要的财产
属性=[“美丽的公式”、“到岸价”、“材料id”]
c=api.query(条件=条件,属性=属性)

安装这两个对我来说很有用:

pip install ipywidgets IProgress

安装这两个对我来说很有用:

pip install ipywidgets IProgress