Skip to content

fix: prevent division by zero in charge corrections#452

Merged
diogomart merged 1 commit intoforlilab:developfrom
diogomart:chrgdivzero
Feb 24, 2026
Merged

fix: prevent division by zero in charge corrections#452
diogomart merged 1 commit intoforlilab:developfrom
diogomart:chrgdivzero

Conversation

@diogomart
Copy link
Copy Markdown
Contributor

Description

Prevent division by zero when all charges are zero in code that makes sure that partial charges sum to an integer.

Type of change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Documentation update
  • Other (please describe):

Checklist:

Please go through the following checklist before submitting the PR:

  • Written a description of the feature or bug fix above.
  • Ran pytest locally and all tests have passed.
  • If applicable, documentation was updated with new feature.
  • Docstring included for any new classes/functions/methods, or for significantly modifed existing functions.
  • (Optional) new test added to account for new feature.

@diogomart diogomart requested a review from joanimato February 23, 2026 19:36
@diogomart diogomart merged commit 3dbac51 into forlilab:develop Feb 24, 2026
2 checks passed
@diogomart diogomart deleted the chrgdivzero branch February 24, 2026 22:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants