Repository navigation
Conversation
A run of tests and examples ended with six warnings: - Suppress numpy's log(0) and log(<0) RuntimeWarnings in the Geomean calculation. The results are unchanged; users with a metric whose mean is zero no longer see a raw numpy warning. - Assert the expected warnings in test_collector_error_handling and test_no_args_function_with_derive_metric with pytest.warns, instead of letting them reach the warnings summary. - Default TRITON_DEFAULT_FP_FUSION to 1 in conftest.py, which keeps Triton's current behavior and silences its Triton 3.9 notice about the default changing in 3.10. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Signed-off-by: Alex Collins <acollins@nvidia.com>
Alok-Joshi
reviewed
Nov 18, 2026
Comment on lines
+312
to
+313
| with pytest.warns(UserWarning, match="does not have a unit specified"): | ||
| result = no_args_with_transform() |
Collaborator
There was a problem hiding this comment.
We should instead update the derive_metric function to return an unit
Collaborator
Author
There was a problem hiding this comment.
Good point, that is the better fix. Done
test_no_args_function_with_derive_metric is about derive_metric on a function without arguments, not about the missing-unit warning, which another test in the same file already asserts. Return (value, unit) so the warning is not raised, instead of expecting it with pytest.warns. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Signed-off-by: Alex Collins <acollins@nvidia.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Removes the six warnings left at the end of a
pytest tests examplesrun.log(0)/log(<0)warnings in the calculation. Results are unchanged.pytest.warns.TRITON_DEFAULT_FP_FUSION=1inconftest.pyto keep current behavior and silence the 3.9 notice.