Skip to content
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

v0.6.0 - modernization release #22

Merged
merged 118 commits into from
Aug 15, 2023
Merged

v0.6.0 - modernization release #22

merged 118 commits into from
Aug 15, 2023

Conversation

rkingsbury
Copy link
Member

@rkingsbury rkingsbury commented Oct 10, 2022

This PR tracks activity related to the next release, v0.6.0

Summary of major changes

  • Replace many Solution.get_XXX methods with properties (see Modernize Solution interface #23)
  • Make Solution serializable via as_dict/from_dict
  • replace the Solute class with a @dataclass defining a schema / document model
  • Complete overhaul of the property database. The database is now distributed in a .json file containing serialize Solute objects. Solution can now be connected to this database (by default) or to any other maggma Store containing properly formatted data. database.py, parameter.py, and all the .tsv data files have been removed and replaced with pyeql_db.json.
  • Implement extensible system for connecting Solution to various activity and speciation models. Models can be
    integrated into pyEQL by implementing an EOS class. The desired activity model is selected on init.
    Currently available models are native (for pyEQL's implementation of Pitzer, which decays gracefully into
    Debye-Huckel and other models if parameters are not available) or ideal for a dummy engine that returns unit
    activity coefficients. Support for additional external engines such as phreeqpython
    is planned. (See New feature: Extensible system for thermodynamic backends #24 )
  • numerous updates to the GitHub actions, pre-commit, linting rules, and CI workflows, and packaging format.

[Unreleased]

Added

  • Solution: add tests to confirm that solution density changes with temperature and pressure
  • Solution: add tests for charge_balance, alkalinity, hardness, osmotic_pressure, p(), and conductivity
  • Solution: pE attribute and kwarg
  • Solution: add support for passing solutes as a dict
  • Implement extensible system for connecting Solution to various activity and speciation
    models. Models can be integrated into pyEQL by implementing an EOS class. The desired
    activity model is selected on init. Currently available models are native (for pyEQL's
    implementation of Pitzer, which decays gracefully into Debye-Huckel and other models if
    parameters are not available) or ideal for a dummy engine that returns unit activity
    coefficients. Support for additional external engines such as phreeqpython is planned.
  • Add pymatgen, monty, and maggma as dependencies
  • Add pre-commit configuration
  • Add pull request template, new GitHub actions, and tox -e autodocs environment to serve and update docs in real time
  • Add pre-commit configuration and lint with ruff using rulesets mostly borrowed from pymatgen
  • Add more comprehensive platform testing via tox

Changed

  • Solution.charge_balance now returns in equivalents instead of Coulombs
  • Docs: update, change theme, and adopt Keep a Changelog format
  • Replace water_properties.py with iapws package
  • Replace elements.py`` with pymatgen.core.periodic_table`
  • Migrate all tests to pytest
  • Update packaging format to use pyscaffold

Deprecated

  • Solution: new properties pressure, temperature, volume, pH, mass, density, viscosity_dynamic, viscosity_kinematic, ionic_strength, conductivity, debye_length, bjerrum_length, alkalinity, hardness, dielectric_constant, osmotic_pressure, solvent_mass, charge_balance have replaced the corresponding get_XXX and set_XXX (for temperature and pressure) methods, which will be removed in a future release. get_viscosity_relative will be removed entirely.
  • Solute: methods get_formal_charge(), get_name(), and get_molecular_weight() have been
    replaced by direct access to the attributes charge, formula, and mw, respectively.

Removed

  • disable 'verbose' kwarg in get_activity and get_activity_coefficient

Fixed

  • Fixed various documentation rendering issues

@rkingsbury rkingsbury closed this Aug 15, 2023
@rkingsbury rkingsbury reopened this Aug 15, 2023
@rkingsbury rkingsbury added the release:minor will issue a minor release label Aug 15, 2023
@rkingsbury
Copy link
Member Author

Closes #24 #23

@rkingsbury rkingsbury merged commit fe34c44 into main Aug 15, 2023
1 of 14 checks passed
@rkingsbury rkingsbury deleted the develop branch August 15, 2023 23:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
release:minor will issue a minor release
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants