-
Notifications
You must be signed in to change notification settings - Fork 22
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Integration of the mp-api
client to pyEQL
#227
Conversation
Tagging @rkingsbury. Is this error related to how |
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## pourbaix #227 +/- ##
===========================================
Coverage ? 71.71%
===========================================
Files ? 13
Lines ? 2680
Branches ? 478
===========================================
Hits ? 1922
Misses ? 676
Partials ? 82 ☔ View full report in Codecov by Sentry. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you @SuixiongTay ! Just a few small edits and this will be ready to merge. Notably, please make sure you install and run pre-commit
to apply linting and formatting to all the new code.
pre-commit install
pre-commit run --all-files
The test look good. We have an issue where tests occasionally fail (as happened here for 1-2 cases) due to some kind of disk or caching problem on the test runners; it means I just have to rerun the tests manually and they usually pass. So you're all good there. |
Thanks for the detailed comments @rkingsbury ! The current revision includes:
|
Thanks @SuixiongTay ! |
Description
This pull request integrates the
mp-api
client to the pourbaix branch ofpyEQL
.1. Ion Reference Data from
MPRester
get_ion_reference_data
frommp-api
.json
file withinmpr_reference_ion_database.json
.2. Integration
mp-api
repository intopourbaix_api.py
:get_ion_reference_data_for_chemsys
get_ion_entries
get_pourbaix_entries
3. Test Integration
test_get_pourbaix_entries
andtest_get_ion_entries
fromtest_mprester.py
.test_pourbaix_api.py
.4.
test_pourbaix_api.py
Editsassert len(bi_v_entry_data) == len(bi_data) + v_data
toassert len(bi_v_entry_data) == len(bi_data) + len(v_data)
.ref_solid_entry = [e for e in ion_ref_entries if e.entry_id == "mp-4770"][0]
toref_solid_entry = [e for e in ion_ref_entries if e.entry_id == "mp-4770-GGA"][0]
.Example Usage