pybamm-team / PyBaMM

Fast and flexible physics-based battery models in Python
https://www.pybamm.org/
BSD 3-Clause "New" or "Revised" License
876 stars 492 forks source link

Fixes #4176 electrode diffusivity rename #4179

Closed BradyPlanden closed 2 weeks ago

BradyPlanden commented 3 weeks ago

Description

Fixes #4176. In addition to this issue, in the develop implementation changes to electrode diffusivity via parameter_values.update() will not be captured. To account for this, the I've taken the depreciated key and appended the new key into parameter_set dictionary in the event that the depreciated parameter is supplied. This also cleans up the bpx.py implementation since the logic for changing the key is moved into the parameters class.

Fixes # (issue)

Type of change

Please add a line in the relevant section of CHANGELOG.md to document the change (include PR #) - note reverse order of PR #s. If necessary, also add to the list of breaking changes.

Key checklist:

You can run integration tests, unit tests, and doctests together at once, using $ python run-tests.py --quick (or $ nox -s quick).

Further checks:

codecov[bot] commented 3 weeks ago

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Project coverage is 99.58%. Comparing base (7d3ef99) to head (c199d3e). Report is 1 commits behind head on develop.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## develop #4179 +/- ## ======================================== Coverage 99.58% 99.58% ======================================== Files 288 288 Lines 21799 21800 +1 ======================================== + Hits 21708 21709 +1 Misses 91 91 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

agriyakhetarpal commented 3 weeks ago

Hi @ejfdickinson, would be able to try these changes out? Also, thanks for flagging this at a reasonable time before the release and thank you @BradyPlanden for taking it!

ejfdickinson commented 2 weeks ago

@agriyakhetarpal @BradyPlanden The test I made is passing with these changes, so seems ok to me. Note also typoes in the changelog!