Skip to content

Several fixes for the CI scripts#2276

Open
lumag wants to merge 3 commits into
qualcomm-linux:masterfrom
lumag:fix-ci
Open

Several fixes for the CI scripts#2276
lumag wants to merge 3 commits into
qualcomm-linux:masterfrom
lumag:fix-ci

Conversation

@lumag
Copy link
Copy Markdown
Contributor

@lumag lumag commented May 24, 2026

The 'Test PR' workflow ends up being executed in the master branch context, checking it our for the for the actions execution. This broke now as the wrynose branch deviated from the master in the terms of the generated artifacts. Test PR now fails to execute testes for the wrynose branch.

lumag added 3 commits May 24, 2026 16:55
The commit abd128c ("Revert "ci: add git_ref input to reusable
build workflows"") dropped git_ref input to the build-yocto workflow.
Follow that change and drop the invalid input usage from the workflow.

Fixes: 8cb4e6b ("ci: build-yocto: add github-cache based build skip mechanism")
Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
The test-distro workflow doesn't have 'distro' input. Use
'inputs.distro_name' for the job name.

Fixes: f522791 ("workflows: refactor test workflow")
Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
Even though the 'Test PR' workflow is being triggered by the workflow
runs in the correct branch, the 'Test PR' is still being triggered
against the default branch. This was not a problem until the commit
3ac51cf ("ci: switch qcom-distro tests to linux-qcom-next kernel")
which created a mismatch between artifacts in the wrynose branch and the
expectations of the test worfklows in the master branch.

Specify the Git ref to be used to checkout the testing actions and
specify it explictly for the 'Test PR' workflows, extracting the info
from the GitHub event.

Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
@github-actions
Copy link
Copy Markdown

Test run workflow

Test jobs for commit 28f29fb

qcom-distro
Pass: 248 | Fail: 3 | Total: 268
nodistro
Pass: 9 | Fail: 0 | Total: 9
qcom-distro_linux-qcom-6.18
Pass: 221 | Fail: 1 | Total: 244

@test-reporting-app
Copy link
Copy Markdown

Test Results

  103 files  ± 0    632 suites  ±0   5h 28m 15s ⏱️ - 1h 20m 25s
  127 tests  -  2     99 ✅  -  1   0 💤 ±0  28 ❌  -  1 
5 994 runs   - 14  5 902 ✅  - 24  39 💤  - 8  53 ❌ +18 

For more details on these failures, see this check.

Results for commit 28f29fb. ± Comparison against base commit c66b499.

This pull request removes 2 tests.
lava ‑ lava-test-retry
lava ‑ lava-test-shell

@lumag
Copy link
Copy Markdown
Contributor Author

lumag commented May 26, 2026

Colleagues,

Without the last fix backported to the wrynose branch, the tests are not being executed / reported correctly.

Copy link
Copy Markdown
Contributor

@mwasilew mwasilew left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this might open the door for running workflows in the context of different repository than meta-qcom. TBH I don't know how to test this properly and make sure it doesn't allow to run tests from random forks in our LAB. I'll try to figure something out today.

@mwasilew
Copy link
Copy Markdown
Contributor

I tried this change and I'm still getting the version of the workflow from master executed on PRs to wrynrose. Investigating further.

@mwasilew
Copy link
Copy Markdown
Contributor

It doesn't seem to be possible to trigger the branch specific workflow with workflow_run trigger. Github always calls a workflow version from master branch. Would it be acceptable to use the event file (which we already save) to pass the target branch to the workflow? This means all branch use cases would need to be addressed in the master workflow. This is the key that can be used:

{
  "pull_request": {
    "base": {
      "ref": "wrynrose",
...

I skipped the redundant keys.

@lumag
Copy link
Copy Markdown
Contributor Author

lumag commented May 28, 2026

It doesn't seem to be possible to trigger the branch specific workflow with workflow_run trigger. Github always calls a workflow version from master branch. Would it be acceptable to use the event file (which we already save) to pass the target branch to the workflow? This means all branch use cases would need to be addressed in the master workflow. This is the key that can be used:

Do you have a contents of github.event somewhere for the comparison?

@mwasilew
Copy link
Copy Markdown
Contributor

Do you have a contents of github.event somewhere for the comparison?

We're saving Event File for each build that is triggered by PR. You can download it from the workflow page. Example:
https://github.com/qualcomm-linux/meta-qcom/actions/runs/26557002069/artifacts/7258518073
from this workflow:
https://github.com/qualcomm-linux/meta-qcom/actions/runs/26557002069

@lumag
Copy link
Copy Markdown
Contributor Author

lumag commented May 28, 2026

Do you have a contents of github.event somewhere for the comparison?

We're saving Event File for each build that is triggered by PR. You can download it from the workflow page. Example: https://github.com/qualcomm-linux/meta-qcom/actions/runs/26557002069/artifacts/7258518073 from this workflow: https://github.com/qualcomm-linux/meta-qcom/actions/runs/26557002069

I don't see events for the 'Test PR build' workflows.

@mwasilew
Copy link
Copy Markdown
Contributor

The event file is saved in build workflow as it's called in the context of PR. Test workflow is executed in the context of main repository so it needs to learn about the PR from this file.

@lumag
Copy link
Copy Markdown
Contributor Author

lumag commented May 28, 2026

The event file is saved in build workflow as it's called in the context of PR. Test workflow is executed in the context of main repository so it needs to learn about the PR from this file.

I'm thinking about the ${{ github.event.workflow_run.foo }}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants