[CI] Parity report: dedupe LOG-BASED FAILURES + fix empty Job ID links#3375
Merged
Conversation
Two fixes to the parity report (both user-reported):
- generate_summary.py: a test could be listed twice in LOG-BASED FAILURES -
once as FAILED and once as CONSISTENT_FAILURE (a one-off FAILED line and a
'FAILED CONSISTENTLY' line describe the same test). Add a shared
_select_rocm_log_failures() helper (used by both the CSV and markdown
tables) that filters out XML-failed tests and dedupes per test, preferring
CONSISTENT_FAILURE so a test is never shown as both.
- download_testlogs: _shorten_unzipped_dirs extracted the upstream CI job id
with re.search(r'_(\\d{6,})\\.zip$'), but the unzipped shard dirs end in
'_<jobid>' with no '.zip' (e.g. ...gfx950.2_83371682957). The id was
dropped, dirs became 'test-default-1-8', and parse_xml_reports_as_dict
couldn't recover it -> the FAILED TESTS 'Job ID' columns were always empty.
Make '.zip' optional: r'_(\\d{6,})(?:\\.zip)?$'.
|
Jenkins build for b19f834b6cbbe67ff5c9de3d1c878448b3f51f80 commit finished as FAILURE |
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.
Two user-reported bugs in the parity report.
1. LOG-BASED FAILURES duplication
A test could be listed twice in the LOG-BASED FAILURES table — once as
FAILEDand once asCONSISTENT_FAILURE— becausedetect_log_failures.pyemits both a per-testFAILEDrecord and aFAILED CONSISTENTLYrecord for the same test, andgenerate_summary.pynever deduped withinlog_failures(it only filtered against the XML FAILED TESTS table).Fix: add a shared
_select_rocm_log_failures()helper (used by both the CSV and markdown renderers) that filters out XML-failed tests and dedupes per test, preferringCONSISTENT_FAILURE— so a test is never shown as both.Example that regressed:
mi350 · default · test_sparse · TestSparseMaskedReductionsCUDA · test_future_empty_dim_masked_prod_cuda_complex128showed as both; it now shows onlyCONSISTENT_FAILURE.2. Empty Job ID columns in FAILED TESTS
download_testlogs._shorten_unzipped_dirsextracted the upstream CI job id withre.search(r'_(\d{6,})\.zip$', ...), but the unzipped shard dirs end in_<jobid>with no.zip(e.g.unzipped-...gfx950.2_83371682957). So the_<jobid>suffix was dropped, dirs becametest-default-1-8, andsummarize_xml'sparse_xml_reports_as_dict(_(\d+)$) couldn't recover the id ->job_urlwas empty for every row -> the FAILED TESTS "Job ID" columns were always blank.Fix: make
.zipoptional:r'_(\d{6,})(?:\.zip)?$'(still matches the older.zipform).Validation
py_compile/ parse clean._select_rocm_log_failureson a reallog_failuresCSV — the test that had bothFAILEDandCONSISTENT_FAILUREcollapses to a singleCONSISTENT_FAILURErow (0 keys left with multiple categories).83371682957from the realunzipped-...dir name, and the resultingtest-distributed-1-3_83371682957parses correctly, sojob_urlpopulates. End-to-endJob IDpopulation will be confirmed by the next parity run after merge.Independent of #3370 / #3371 (those touch a different section of
generate_summary.py).Made with Cursor
Validation
Validated on a run of this PR branch (develop + both fixes) for the exact SHA that exhibited both bugs:
206283a284889f3a4f62510f8b5a8068d41121c4 · mi350: https://github.com/ROCm/pytorch/actions/runs/28190615761test_sparse::TestSparseMaskedReductionsCUDA::test_future_empty_dim_masked_prod_cuda_complex128is now listed once asCONSISTENT_FAILURE(was both FAILED + CONSISTENT_FAILURE); 0 keys with multiple categories across the LOG-BASED table.job_url_rocmwent 0 -> 308,793 andjob_url_cuda0 -> 354,344 non-empty.Also applied to
ethanwee1/pytorch@main(fe21d4e); the fork run (https://github.com/ethanwee1/pytorch/actions/runs/28189128743) confirms Bug 1. Note: the fork'ssummarize_xml_testreports.pypredates develop's_wf_run_id->job_urlfeature, so Job IDs there populate once the fork syncs that fromdevelop(Bug 2's fix is thedownload_testlogsregex, which is on the fork).