-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Fix user warnings #2906
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
Fix user warnings #2906
Conversation
for more information, see https://pre-commit.ci
|
Performance benchmarks:
|
|
While I do appreciate your effort, I thought I specifically requested one kind of warning at the time. That’s (also) to keep stuff reviewable for us. Both in size, as in scope (different reviewers have different expertises). Could you open smaller, atomic PR’s that treats one kind of warning each? Especially split the visualization stuff from the RNG stuff. |
output_solara_utf8.txt
Outdated
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.
Try not to include these kind of files
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.
Ok @EwoutH I will
|
@EwoutH Please review my PR. |
|
Unfortunately you’re still doing multiple things at the same time. Maybe it’s easier to split off some of the original commits to a new branch, and open a new PR? |
Okay sure i will fix the copy in my local machine and raise a new PR regarding the issue 2.1. |
Summary
This PR removes several noisy warnings (
UserWarning+ oneDeprecationWarning) from tests/examples and adds regression tests to prevent them from returning. The changes improve determinism, clean test output, and stabilize CI.Issue:#2904
Bug / Issue
The test suite emitted:
OrthogonalMooreGrid,Network,VoronoiGrid) created without an explicit RNG → non-deterministic tests.default_val=0used withdtype=np.float64.s,c,linecolorsignored by the matplotlib backend.test_components_matplotlib.py.Implementation
random.Random(42)to all grid/network/voronoi instantiations in tests/examples.PropertyLayerdefaults to0.0ornp.float64(0)when dtype is float.size,color,edgecolorsand added minimal normalization in the matplotlib backend.test_examples_viz.py.Testing
pytest -qpasses and warnings are gone.Additional Notes