Red Hat Satellite engineering is moving the tracking of its product development work on Satellite to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "Satellite project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs will be migrated starting at the end of May. If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "Satellite project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/SAT-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Bug 2105299 - Email notification shows incorrect new errata after syncing an Epel repository
Summary: Email notification shows incorrect new errata after syncing an Epel repository
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Satellite
Classification: Red Hat
Component: Errata Management
Version: 6.10.6
Hardware: Unspecified
OS: Unspecified
unspecified
medium
Target Milestone: 6.12.0
Assignee: wclark
QA Contact: addubey
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2022-07-08 13:04 UTC by Hao Chang Yu
Modified: 2024-03-14 16:20 UTC (History)
10 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
: 2122177 (view as bug list)
Environment:
Last Closed: 2022-11-16 13:34:16 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Foreman Issue Tracker 35191 0 Normal Assigned Email notification shows incorrect new errata after syncing an Epel repository 2022-08-25 14:15:54 UTC
Red Hat Issue Tracker SAT-11580 0 None None None 2022-08-17 14:05:39 UTC
Red Hat Product Errata RHSA-2022:8506 0 None None None 2022-11-16 13:34:30 UTC

Description Hao Chang Yu 2022-07-08 13:04:26 UTC
Description of problem:
I found that 130 errata in the Epel 8 repository always reported as new Errata in the summary of the email notification. Same issue is also observed in Epel 7 repository.

This is caused by the discrepancy between the Pulp update records and the Katello errata records.

1. Some Errata in EPEL repo have trailing whitespace in the description field. Katello strips the trailing whitespace and save the errata into the DB. When comparing this field, both of them don't match due to the trailing whitespace so consider as updated.


Example:
----------------------------------------------
Katello DB
{
  "errata_id"=>"FEDORA-EPEL-2021-3d5da78e55",
  "title"=>"openssh-ldap-authkeys-0.1.0~git20200205.aee4c46-2.el8",
  "description"=>"Initial packaging for Fedora",
}


# Pulp update record
{
  "errata_id"=>"FEDORA-EPEL-2021-3d5da78e55",
  "title"=>"openssh-ldap-authkeys-0.1.0~git20200205.aee4c46-2.el8",
  "description"=>"Initial packaging for Fedora\n",   <================ Trailing whitespace.
}
----------------------------------------------


2. Some Errata in EPEL have none standard long title. Katello limits the Errata title to 255 characters and will truncate the rest. When comparing this field, both of them don't match so consider as updated.


Example:
----------------------------------------------
# Katello DB
{
  "errata_id"=>"FEDORA-EPEL-2021-b87459fd6f",
  "title"=>"certbot-1.22.0-1.el8 python-acme-1.22.0-1.el8 python-certbot-apache-1.22.0-1.el8 python-certbot-dns-cloudflare-1.22.0-1.el8 python-certbot-dns-cloudxns-1.22.0-1.el8 python-certbot-dns-digitalocean-1.22.0-1.el8 python-certbot-dns-dnsimple-1.22.0-1.el8 p...",  <============== Truncated
  "description"=>"update to 1.22.0",
}


# Pulp update record
{
  "errata_id"=>"FEDORA-EPEL-2021-b87459fd6f"
  "title"=>"certbot-1.22.0-1.el8 python-acme-1.22.0-1.el8 python-certbot-apache-1.22.0-1.el8 python-certbot-dns-cloudflare-1.22.0-1.el8 python-certbot-dns-cloudxns-1.22.0-1.el8 python-certbot-dns-digitalocean-1.22.0-1.el8 python-certbot-dns-dnsimple-1.22.0-1.el8 python-certbot-dns-dnsmadeeasy-1.22.0-1.el8 python-certbot-dns-gehirn-1.22.0-1.el8 python-certbot-dns-google-1.22.0-1.el8 python-certbot-dns-linode-1.22.0-1.el8 python-certbot-dns-luadns-1.22.0-1.el8 python-certbot-dns-nsone-1.22.0-1.el8 python-certbot-dns-ovh-1.22.0-1.el8 python-certbot-dns-rfc2136-1.22.0-1.el8 python-certbot-dns-route53-1.22.0-1.el8 python-certbot-dns-sakuracloud-1.22.0-1.el8 python-certbot-nginx-1.22.0-1.el8", 
  "description"=>"update to 1.22.0",
}
----------------------------------------------




Steps to Reproduce:
1. Login and subscribe the user to sync errata email.
2. Create a repository to sync Epel 8 repository. Url: https://dl.fedoraproject.org/pub/epel/8/Everything/x86_64/
3. Sync the repository and you should get an email notification which will report all errata as new (excluding some unknown Fedora errata types).
4. Do a complete sync and wait for the task to finish.


Actual results:
Received and email notification reporting 130 new errata.


Expected results:
Should not send email notification because there is no new errata.



Additional info:
The discrepancy mentioned above also happened in Satellite 6.9.9 but it is reporting the new errata correctly because Satellite 6.9.9 won't update the RepositoryErratum association. It will only create new RepositoryErratum association for new errata.

Comment 5 wclark 2022-08-08 14:28:02 UTC
*** Bug 2116375 has been marked as a duplicate of this bug. ***

Comment 19 errata-xmlrpc 2022-11-16 13:34:16 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory (Important: Satellite 6.12 Release), and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHSA-2022:8506


Note You need to log in before you can comment on or make changes to this bug.