ci: add build and kernel metadata to LAVA jobs - #3108
Matt H (mattface) wants to merge 1 commit into
Conversation
| name: ${{ steps.print-output.outputs.filename }} | ||
| path: ${{ steps.print-output.outputs.filename }} | ||
|
|
||
| - name: Upload build metadata |
There was a problem hiding this comment.
This might take us above the allowed artifact threshold (again) quickly. I'm not sure how to prevent the problem. Maybe upload to S3?
There was a problem hiding this comment.
Size or count? I can bundle this into the other artifact to keep the count down?
| INPUTS_MACHINE: ${{ inputs.machine }} | ||
| INPUTS_DISTRO_NAME: ${{ inputs.distro_name }} | ||
| INPUTS_KERNEL_DIRNAME: ${{ inputs.kernel_dirname }} | ||
| - name: Extract build metadata from the image SBOM |
There was a problem hiding this comment.
turn it into action so you can install python dependencies properly.
There was a problem hiding this comment.
Theres no python dependencies to install, all are in stdlib I believe
There was a problem hiding this comment.
IIUC you can't assume python is available in the action worker (it's there in most cases). If python is used in the action you should install it like so:
steps:
...
- uses: actions/setup-python@v6
with:
python-version: 3.11
|
Pushed to |
Test Results 69 files - 50 294 suites - 421 3h 57m 33s ⏱️ - 5h 29m 24s For more details on these failures, see this check. Results for commit e89c1cb. ± Comparison against base commit c672971. This pull request removes 24 tests.♻️ This comment has been updated with latest results. |
0ad8374 to
908e505
Compare
|
Milosz Wasilewski (@mwasilew) I've added a bump to LAVA_TEST_PLANS_REF in here, so if you push this to next again, it should show actual metadata in the LAVA jobs. I can always remove that change for this to be merged here later. |
|
Something didn't work. This is one of the jobs from the |
Previous version of the patch (the one you pushed to next already) didnt have the LAVA_TEST_PLANS_REF change, so no new metadata will have been added. |
|
Pushed new version to |
|
New version works as expected. Here is an example job: https://lava.infra.foundries.io/scheduler/job/414293/definition#defline15 It needs to be confirmed whether this would work with PR as well. |
|
Some additional input form my little robot friend: Fix before merge:
Wrong or inconsistent metadata:
Robustness and cleanup:
|
Jobs recorded the build URL, pull request and workflow run, but not the commit they were built from, the configuration under test, or the kernel in the image, and none of it could be queried. The source repository, commit, branch and build type are derived from the event; the distro, build config, image, test plan and build machine the action already knows; the kernel's recipe, repository, commit and release are read from the SPDX SBOM every build already writes and passed over as an artifact. Everything is written as EXTRA_METADATA in JSON variables files passed alongside the existing one, so recording a new key needs no change in lava-test-plans. Bump the pinned lava-test-plans revision to one that renders it. Signed-off-by: Matt Hart <matthart@qti.qualcomm.com>
908e505 to
e89c1cb
Compare
|
I believe I've covered all the comments, except I purposely chose to not parse out nightly/weekly for the build-type. Anyone who wants to, can do so from the gh-workflow-name metadata. Other repos like 3rdparty/arduino will now quietly not create any new metadata until the script is introduced there. |
Jobs recorded the build URL, pull request and workflow run, but not the commit they were built from, the configuration under test, or the kernel in the image, and none of it could be queried.
The commit, branch and build type are derived from the event; the machine, distro, kernel, image and test plan the action already knows; the kernel's recipe, repository, commit and release are read from the SPDX SBOM every build already writes and passed over as an artifact.
They are written to a per-machine EXTRA_METADATA variables file passed alongside the existing one, so recording a new key needs no change in lava-test-plans.
This has no effect until the LAVA_TEST_PLANS_REF is bumped, but should quietly not add any metadata until that time.