The 'errors' record for series now counts all errors for tests/series.#785
Open
Paul-Ferrell wants to merge 1 commit into
Open
The 'errors' record for series now counts all errors for tests/series.#785Paul-Ferrell wants to merge 1 commit into
Paul-Ferrell wants to merge 1 commit into
Conversation
hwikle-lanl
requested changes
Sep 27, 2024
| status_file.SERIES_STATES.KICKOFF_ERROR): | ||
| errors += 1 | ||
| for error_val in error_values: | ||
| if error_val in status.state: |
Collaborator
There was a problem hiding this comment.
Using str.__contains__ here feels a bit kludgey and error-prone. A better solution would be to implement a mechanism to separate statuses into ERROR, CANCELLED, and TIMEOUT classes, either by:
a) Creating something like a class field on TestStatusInfo that takes on an enum value and testing against that; or
b) Implementing three static methods on StatesStruct that return sets of ERROR, CANCELLED, and TIMEOUT statuses respectively and then checking whether status.state is contained within each set (or simply the union of the three sets).
Collaborator
There was a problem hiding this comment.
The second option feels cleaner to me.
| # Look for any bad test states | ||
| for error_val in error_values: | ||
| for state in test_info.state_history: | ||
| if error_val in state.state: |
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.
I've noticed that the 'errors' number when running
pav series statusdoesn't include all test errors, like timeouts and other errors. It should with this change.Code review checklist: