Skip to content

Patch test_components fromJSON error when test_runs_on is empty#4930

Merged
ScottTodd merged 1 commit into
mainfrom
users/scotttodd/test-artifacts-robustness
Apr 29, 2026
Merged

Patch test_components fromJSON error when test_runs_on is empty#4930
ScottTodd merged 1 commit into
mainfrom
users/scotttodd/test-artifacts-robustness

Conversation

@ScottTodd
Copy link
Copy Markdown
Member

Motivation

This dev release in rockrel: https://github.com/ROCm/rockrel/actions/runs/25100364100/attempts/1 hit errors
Multi-Arch Release Error when evaluating 'strategy' for job 'test_components'. ROCm/TheRock/.github/workflows/test_artifacts.yml@30fc752307885b3099b9a25b2fde039928d8a651 (Line: 176, Col: 21): Error from function 'fromJSON': empty input, ROCm/TheRock/.github/workflows/test_artifacts.yml@30fc752307885b3099b9a25b2fde039928d8a651 (Line: 176, Col: 21): Unexpected value ''

Technical Details

I think we missed this in CI workflows since multi_arch_ci_linux.yml has a expect_failure condition:

test_artifacts_per_family:
needs: [copy_prebuilt_stages, build_multi_arch_stages]
name: Test ${{ matrix.family_info.amdgpu_family }}
# If we are expecting a build failure, do not run tests to save machine capacity.
if: ${{ !failure() && !cancelled() && fromJSON(inputs.build_config).expect_failure == false }}

I did not add that condition to multi_arch_release_linux.yml:

test_artifacts_per_family:
needs: [build_artifacts]
name: Test ${{ matrix.family_info.amdgpu_family }}
if: ${{ !failure() && !cancelled() }}

I'd like to remove that expect_failure entirely since it isn't actually working right now in multi-arch CI, see #4500

Test Plan

We'll need to run a release workflow until it reaches the test step, which takes hours. Might as well merge and test via an actual dev release.

Submission Checklist

When configure_test_matrix is skipped (test_runs_on is empty), its
components output is an empty string. The existing guard only checked
for '[]', so empty string passed the if condition and fromJSON('')
failed with "empty input".

This was exposed by PR #4911 which calls test_artifacts.yml from
release workflows for all families, including those without test
runners (gfx900, gfx906, gfx908, gfx101x, etc.).

Changes:
- Add != '' guard so test_components is skipped when
  configure_test_matrix was skipped
- Add || '[]' fallback in fromJSON for defense in depth

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
@ScottTodd ScottTodd merged commit 30905dc into main Apr 29, 2026
25 checks passed
@ScottTodd ScottTodd deleted the users/scotttodd/test-artifacts-robustness branch April 29, 2026 17:33
@github-project-automation github-project-automation Bot moved this from TODO to Done in TheRock Triage Apr 29, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

2 participants