Skip to content

Conversation

@ximiali
Copy link
Contributor

@ximiali ximiali commented Nov 12, 2025

Description

Add a new hardware_summary action to the notifications management command.
This action generates hardware reports based on the hardware subscription files.

Changes

  • Add a new hardware_summary action to the notifications command with CLI argument.
  • Add functions to parse hardware subscription files, query hardware data, and normalize hardware results.
  • Add Jinja template for email reports.
  • Add example and Qualcomm hardware subscription files.

How to Test

Run the following command to generate the hardware summary report:

poetry run python manage.py notifications --action hardware_summary 

Related Issue

Closes #1081

@ximiali ximiali force-pushed the notifications-hardware-summary-report branch 2 times, most recently from 629b5a1 to 269cd86 Compare November 12, 2025 08:44
@MarceloRobert
Copy link
Collaborator

Hello and thanks for the contribution! We will check this PR as soon as we can.

For now, please check the lint rules, you can use the linter locally to check for required changes. Commit and PR description looks good!

I glanced over the changes and they look well written, I would just make a nitpick for leaving a \n at the end of the last line on the new files, GitHub marks those problems with a symbol at the end of the file.

@padovan
Copy link
Contributor

padovan commented Nov 12, 2025

Hello, Thanks for this. Can you also attach and example output from running this command. I want to review how the report output is coming out.

@ximiali ximiali force-pushed the notifications-hardware-summary-report branch 2 times, most recently from 2f1cc1a to 603424a Compare November 13, 2025 08:04
@ximiali
Copy link
Contributor Author

ximiali commented Nov 13, 2025

Hello, Thanks for this. Can you also attach and example output from running this command. I want to review how the report output is coming out.

Thanks for your feedback! Here’s an example report output, showing only a limited number of items for clarity.

Hello,

Status summary for qcs9100-ride

Builds:    43 ✅    0 ❌    0 ⚠️
Boots:       0 ✅    0 ❌    0 ⚠️
Tests:      55 ✅    5 ❌   39 ⚠️
-------------

#kernelci test maestro:685eb3af5c2cf25042e8983b
- Status: FAIL
- Comment: baseline-arm64-qualcomm on qcs9100-ride in lava-kci-qualcomm
- Starttime: 2025-06-27 15:07:27.269000+00:00
- Tree: next/master
- Origin: maestro
- Test_lab: lava-kci-qualcomm
- Commit: 2aeda9592360c200085898a258c4754bfe879921
- Dashboard: https://dashboard.kernelci.org/test/maestro:685eb3af5c2cf25042e8983b
-------------


--
This is an experimental report format. Please send feedback in!
Talk to us at [email protected]

Made with love by the KernelCI team - https://kernelci.org/
'''

@padovan
Copy link
Contributor

padovan commented Nov 13, 2025

It is looking great. Thanks for sharing. I am fine with the output being generated and with the yaml config file for hardware.

I'll let the Dashboard team review it in detail and comment on the implementation.

Copy link
Collaborator

@MarceloRobert MarceloRobert left a comment

Choose a reason for hiding this comment

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

Could you update the notifications.md document with this new command too?

@ximiali ximiali force-pushed the notifications-hardware-summary-report branch from 603424a to 5d7b78a Compare November 17, 2025 02:47
Copy link
Collaborator

@MarceloRobert MarceloRobert left a comment

Choose a reason for hiding this comment

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

If you want to have automatic reports, you have to add a cron job in settings.py like the other ones set up there. Also please fix the CI issues, otherwise it looks good now

Add new hardware_summary action in the notifications management
command. This action generates hardware reports based on the subscription
file.

Signed-off-by: Yushan Li <[email protected]>
@ximiali ximiali force-pushed the notifications-hardware-summary-report branch from 5d7b78a to e37285a Compare November 18, 2025 07:55
@ximiali
Copy link
Contributor Author

ximiali commented Nov 18, 2025

If you want to have automatic reports, you have to add a cron job in settings.py like the other ones set up there. Also please fix the CI issues, otherwise it looks good now

Thanks, added a cron job in settings.py to trigger the hardware report every Monday, and also fixed the CI issues.

Copy link
Collaborator

@MarceloRobert MarceloRobert left a comment

Choose a reason for hiding this comment

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

Looking great

@MarceloRobert MarceloRobert added this pull request to the merge queue Nov 18, 2025
Merged via the queue into kernelci:main with commit c386899 Nov 18, 2025
7 checks passed
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.

notifications: add recipients list based on hardware where the test executed

3 participants