Bug 1801910

Summary: Errata excludes filter by date seems to include wrong modular errata
Product: Red Hat Satellite Reporter: Partha Aji <paji>
Component: Content ViewsAssignee: Partha Aji <paji>
Status: CLOSED ERRATA QA Contact: Lai <ltran>
Severity: medium Docs Contact:
Priority: unspecified    
Version: 6.7.0CC: rkarimpa
Target Milestone: 6.7.0Keywords: Triaged
Target Release: Unused   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: tfm-rubygem-katello-3.14.0.16-1 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2020-04-14 13:38:51 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Partha Aji 2020-02-11 22:12:08 UTC
Using a content view filter to exclude errata after a certain date is not working correctly in Satellite 6.7.  This was working as expected in Satellite 6.5.  The filters were created in the Web UI, and also with hammer using these commands:


# hammer content-view filter create \
> --type erratum \
> --name "No errata after 20191110" \
> --description "No errata after 20191110" \
> --inclusion false \
> --organization-id 1 \
> --repository-ids 1,2,3 \
> --content-view CV-1
Filter created.

# hammer content-view filter rule create \
> --organization-id 1 \
> --content-view CV-1 \
> --content-view-filter "No errata after 20191110" \
> --date-type "issued" \
> --start-date 2019-11-10 \
> --types "security,bugfix,enhancement"

The repositories tested are:

   Red Hat Enterprise Linux 8 for x86_64 - AppStream RPMs x86_64 8


Version-Release number of selected component (if applicable):
Satellite 6.7

How reproducible:
Always

Steps to Reproduce:
1. Create a content view with RHEL 8 repos (AppStream)
2. Create filter and filter rule that excludes erratas after a certain date (either issued or updated)
3. Publish Content View

Actual results:
Some errata are included that were both "updated" and "issued" after the filter date.

Expected results:
Erratas should only be included if they were issued/updated prior to the filter date.


Additional info:
Note 6.7 filters on the modular errata while 6.6 does not. Hence its expected to work in 6.7 but not 6.6

Comment 3 Partha Aji 2020-02-11 22:55:00 UTC
Connecting redmine issue https://projects.theforeman.org/issues/28988 from this bug

Comment 4 Bryan Kearney 2020-03-04 15:03:20 UTC
Moving this bug to POST for triage into Satellite 6 since the upstream issue https://projects.theforeman.org/issues/28988 has been resolved.

Comment 6 Lai 2020-03-17 21:02:53 UTC
Steps to test:

1. Enable and sync "Red Hat Enterprise Linux 8 for x86_64 - AppStream RPMs x86_64 8"
2. Create a content view with RHEL 8 repos (AppStream1
3. Create filter and filter rule that excludes erratas after a certain date (either issued or updated) - I tested both for after 12/01/2019.
4. Publish Content View
5. Drill into version published and go to "Errata" tab.

Actual results:
Erratas only included if they issued/updated prior to the filter date.  Saw "Update" columns on all errata before 12/01/2019.

Expected results:
Erratas should only be included if they were issued/updated prior to the filter date.  You should see the list of dates on the "Updated" column with erratas before 12/01/2019.


Verified on 6.7.0_016

Additional note: Tested this using hammer commands as stated above and also produced same results.

Comment 7 Lai 2020-03-17 21:03:34 UTC
Forgot to set to verified so setting it now.

Comment 8 Bryan Kearney 2020-04-14 13:38:51 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, 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-2020:1454