-
Notifications
You must be signed in to change notification settings - Fork 61
Giving opposite boundaries different names no longer causes a symmetry validator failure #2682
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
Conversation
c969a44
to
6c3eaa1
Compare
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.
Reviewing changes made in this pull request
Diff CoverageDiff: origin/develop...HEAD, staged and unstaged changes
Summary
|
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.
Thanks @jewettaijfc looks great! Just a minor nitpick.
b7bffdd
to
ea07ccc
Compare
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.
LGTM!
This small PR solves issue #2635 .
name
attribute of theplus
andminus
boundary conditions, when deciding whetherplus
andminus
are identical.Test instructions
Automatic Tests
Manual tests
To test manually, run the following code snippet and confirm that no errors are generated:
(Previously, the
_validate_boundary_spec_symmetry()
validator would fail.)Greptile Summary
This PR fixes a bug in the boundary condition symmetry validation logic. Previously, when users set different names for physically identical boundary conditions on opposite sides (plus/minus), the validator would incorrectly fail. The fix modifies the validation to ignore the
name
attribute when comparing boundaries, focusing only on their physical properties.The changes involve:
equivalent()
function to make copies of boundaries with empty names before comparisoncopy(update=...)
method to properly handle the comparisonThis change improves usability by allowing users to give meaningful names to their boundary conditions without triggering false validation errors, while still maintaining proper symmetry validation for the physical properties that matter.
Confidence score: 5/5
2 files reviewed, no comments
Edit PR Review Bot Settings | Greptile