Bug 2112419

Summary: Content View publish fails with error PG::CardinalityViolation: ERROR: ON CONFLICT DO UPDATE command cannot affect row a second time.
Product: Red Hat Satellite Reporter: Odilon Sousa <osousa>
Component: Content ViewsAssignee: Lucy Fu <lufu>
Status: CLOSED ERRATA QA Contact: Lai <ltran>
Severity: high Docs Contact:
Priority: high    
Version: 6.10.3CC: ahumbe, iballou, jsenkyri, karnsing, lufu, pdwyer, phess, saydas
Target Milestone: 6.11.2Keywords: PrioBumpGSS, Triaged
Target Release: Unused   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: tfm-rubygem-katello-4.3.0.46-1 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: 2070535 Environment:
Last Closed: 2022-08-30 19:43:07 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Comment 3 Lai 2022-08-09 03:08:46 UTC
Steps to retest:
1. Create a content view using the below repository
~~~
 1) Id:    1
    Name:  Red Hat Enterprise Linux 7 Server RPMs x86_64 7Server
    Label: Red_Hat_Enterprise_Linux_7_Server_RPMs_x86_64_7Server
 2) Id:    9
    Name:  Red Hat Enterprise Linux 7 Server - RH Common RPMs x86_64 7Server
    Label: Red_Hat_Enterprise_Linux_7_Server_-_RH_Common_RPMs_x86_64_7Server
 3) Id:    7
    Name:  Red Hat Enterprise Linux 7 Server - Optional RPMs x86_64 7Server
    Label: Red_Hat_Enterprise_Linux_7_Server_-_Optional_RPMs_x86_64_7Server
 4) Id:    6
    Name:  Red Hat Enterprise Linux 7 Server - Extras RPMs x86_64
    Label: Red_Hat_Enterprise_Linux_7_Server_-_Extras_RPMs_x86_64
 5) Id:    4
    Name:  Red Hat Software Collections RPMs for Red Hat Enterprise Linux 7 Server x86_64 7Server
    Label: Red_Hat_Software_Collections_RPMs_for_Red_Hat_Enterprise_Linux_7_Server_x86_64_7Server
~~~
2. Publish the content view

Expected result:
Content view should publish without errors

Actual:
content view does publish without errors

Verified on 6.11.2 snap 1 with rubygem-katello-4.3.0.46-1.el8sat.noarch on rhel7 and rhel8

Comment 9 errata-xmlrpc 2022-08-30 19:43:07 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 (Satellite 6.11.2 Async Bug Fix Update), 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/RHBA-2022:6233