materialsproject / api

New API client for the Materials Project
https://materialsproject.github.io/api/
Other
104 stars 38 forks source link

Option to suppress progress bar and some unneeded warnings #812

Closed shyuep closed 11 months ago

shyuep commented 1 year ago

The output from MPRester is too noisy, esp for Jupyter notebooks. I suggest providing at least an init arg to suppress the progress bar.

Second, some warnings are used by very few people and should not be always prompted by default. E.g.,

UserWarning: mpcontribs-client not installed. Install the package to query MPContribs data, or construct pourbaix diagrams: 'pip install mpcontribs-client'
munrojm commented 1 year ago

This is currently setup as an env variable, but I agree it needs to be an input arg to MPRester. I will add that now, and also suppress the mpcontribs warning unless that client is trying to be used.

Jverduzc commented 11 months ago

Hello! Has this been added to the args of MPRester?

munrojm commented 11 months ago

Yes, this is now in the latest release.