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 1744254 - Unable to remove puppet module by uuid from content-view using hammer
Summary: Unable to remove puppet module by uuid from content-view using hammer
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Satellite
Classification: Red Hat
Component: Content Views
Version: 6.6.0
Hardware: Unspecified
OS: Unspecified
unspecified
medium
Target Milestone: 6.6.0
Assignee: Ian Ballou
QA Contact: Lai
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2019-08-21 16:11 UTC by Lai
Modified: 2019-10-22 19:47 UTC (History)
2 users (show)

Fixed In Version: rubygem-katello-3.12.0.21-1
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2019-10-22 19:47:48 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Foreman Issue Tracker 27718 0 None None None 2019-08-27 18:08:56 UTC

Description Lai 2019-08-21 16:11:33 UTC
Description of problem:
Trying to remove a puppet-module's UUID from content-view gives warning that uuid cannot be found when it clearly shows that it's present in the content-view.

Version-Release number of selected component (if applicable):
6.6.0 Snap 16

How reproducible:
100%

Steps to Reproduce:
1. Create a repo with puppet module
2. Sync repo
3. Create a content-view and add puppet module in
4. Remove puppet module using hammer command: hammer content-view puppet-module remove --content-view-id=<id> --uuid=<uuid>

Actual results:
Couldn't remove puppet module from the content view
Error: content_view_puppet_module not found.

Expected results:
Successfully remove puppet module form the content view.

Comment 3 Lai 2019-08-21 16:18:31 UTC
This is a regression issue.  Tested on 6.5.2 and it passed there.  For QE testing, just run the automation test: tests/foreman/cli/test_contentview.py::ContentViewTestCase::test_positive_remove_puppet_module_by_uuid

Comment 4 Jonathon Turel 2019-08-21 16:18:48 UTC
From the logs:

2019-08-21T11:51:21 [E|app|0d35d2fd] Invalid search: PG::UndefinedColumn: ERROR:  column katello_content_view_puppet_modules.pulp_id does not exist
LINE 1: ...t_view_puppet_modules"."content_view_id" = $1 AND "katello_c...
                                                             ^
: SELECT COUNT(DISTINCT "katello_content_view_puppet_modules"."id") FROM "katello_content_view_puppet_modules" WHERE "katello_content_view_puppet_modules"."content_view_id" = $1 AND "katello_content_view_puppet_modules"."pulp_id" = $2
2019-08-21T11:51:21 [I|app|0d35d2fd]   Rendering /opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.12.0.9/app/views/katello/api/v2/content_view_puppet_modules/index.json.rabl within katello/api/v2/layouts/collection
2019-08-21T11:51:21 [I|app|0d35d2fd]   Rendered /opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.12.0.9/app/views/katello/api/v2/content_view_puppet_modules/index.json.rabl within katello/api/v2/layouts/collection (1.5ms)

Comment 6 Ian Ballou 2019-08-27 18:08:55 UTC
Created redmine issue https://projects.theforeman.org/issues/27718 from this bug

Comment 7 Bryan Kearney 2019-09-03 18:06:35 UTC
Moving this bug to POST for triage into Satellite 6 since the upstream issue https://projects.theforeman.org/issues/27718 has been resolved.

Comment 9 Lai 2019-09-16 21:21:19 UTC
Steps to Test:
1. Create a repo with puppet module
2. Sync repo
3. Create a content-view and add puppet module in.  (be sure to NOT select "Always use latest")
4. Remove puppet module using hammer command: hammer content-view puppet-module remove --content-view-id=<id> --uuid=<uuid>

Expected result:
Puppet module removed from content view.

Actual result:
Puppet module removed from content view.

Verified on 6.6.0 snap 20.

Marking issue as verified.

Comment 10 Bryan Kearney 2019-10-22 19:47:48 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-2019:3172


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