[Katello] errata notification e-mail displays all errata

Problem:
Errata notification e-mail is showing all errata, no matter how many syncs.

Expected outcome:
Only latest errata should be displayed. If the errata displayed the date they were released in the e-mail, that’d be a nice bonus.

Foreman and Proxy versions:
Foreman 3.4 Katello 4.6

Foreman and Proxy plugin versions:

Distribution and version:
AlmaLinux 8

Other relevant data:

The synchronization of “AlmaLinux 8 EPEL (x86_64)” has completed. Below is a summary of new errata. A large number of errata were synced for this repository, so only the first 100 are shown.

New Errata

[92] SECURITY
[492] BUGFIX
[561] ENHANCEMENT

This looks like it could be Bug #35191: Email notification shows incorrect new errata after syncing an Epel repository - Katello - Foreman

I’ll untriage it to see if we can get it into Katello 4.6.1 instead of 4.7.

1 Like

This happens for all repos, not just EPEL, we have our own internal repos.
It can tell there is new errata, the e-mail doesn’t arrive if there isn’t any, but it won’t display just the latest.

Thanks for having a look at it!

1 Like

Out of EPEL repos, I can see only “AlmaLinux 8 EPEL” sending notification despite there being no change in the number of errata. Maybe formatting changes or errata version update, I haven’t dug deeper into that.

1 Like

we’ve seen this happen for a couple different reasons in various builds

  1. trailing whitespace in an errata description gets stripped when stored by pulp, so every time katello syncs a repo and compares the errata it found there vs. the errata it already stored in pulp, it looks different or “new”
  2. similar to above, pulp also truncates the title to 255 characters

for the EPEL repos specifically, these issues were the culprit because some specific errata there were able to cause the above conditions. together, these causes constitute Bug #35191: Email notification shows incorrect new errata after syncing an Epel repository - Katello - Foreman

then there is a 3rd known cause which can affect any/all repositories

  1. the task which sends the email notification looks for new errata by making a comparison on the updated_at field of the repository_errata relation rather than using updated_at field on the erratum itself… this appears to be a bug that was introduced while trying to fix some previous issues with errata notification emails

this different bug is tracked separately with Bug #35503: Errata Mail calculates updated_at date per repository, should be per erratum - Katello - Foreman

depending on the version and the # of repositories affected, you may be running into either of these issues

1 Like