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 1427261 - Hammer- can't remove puppet module from content view by id -- uuid is sent instead
Summary: Hammer- can't remove puppet module from content view by id -- uuid is sent in...
Keywords:
Status: CLOSED DUPLICATE of bug 1427260
Alias: None
Product: Red Hat Satellite
Classification: Red Hat
Component: Content Views
Version: 6.3.0
Hardware: Unspecified
OS: Unspecified
unspecified
medium
Target Milestone: Unspecified
Assignee: satellite6-bugs
QA Contact:
URL:
Whiteboard:
Depends On: 1427260
Blocks:
TreeView+ depends on / blocked
 
Reported: 2017-02-27 17:37 UTC by Stanislav Tkachenko
Modified: 2017-03-01 11:41 UTC (History)
5 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of: 1427260
Environment:
Last Closed: 2017-03-01 11:41:14 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description Stanislav Tkachenko 2017-02-27 17:37:30 UTC
+++ This bug was initially created as a clone of Bug #1427260 +++

Description of problem:

Can't remove puppet module from content view by id using hammer. According to hammer debug, uuid is sent instead of id:
>[ INFO 2017-02-27 12:29:08 HammerCLIKatello::ContentView] Called with options: {}
> [ INFO 2017-02-27 12:29:08 HammerCLIKatello::ContentViewPuppetModule] Called with options: {}
> [ INFO 2017-02-27 12:29:08 API] Server: https://localhost/
> [ INFO 2017-02-27 12:29:08 API] GET /katello/api/content_views/118/content_view_puppet_modules
> [DEBUG 2017-02-27 12:29:08 API] Params: {
>    "uuid" => "44"
>}
>[DEBUG 2017-02-27 12:29:08 API] Headers: {
>    :params => {
>        "uuid" => "44"
>    }
>}

Also it is not clear what exactly id should be used, the one from global `puppet-module list` command output, like it is done for `content-view puppet-module add`, or from the `content-view info` output. However, both doesn't allow to remove puppet module. --name and --uuid parameters work as expected.

> # hammer -v content-view info --id 121
> Puppet Modules:         
> 1) ID:      46
>    UUID:    2de63c7f-d0fb-4a29-b301-449a52c026d7
>    Name:    generic_1

> # hammer -v content-view puppet-module remove --content-view-id="121" --id="46"
> [ERROR 2017-02-27 12:05:29 Exception] Error: content_view_puppet_module not found
> Couldn't remove puppet module from the content view:
>  Error: content_view_puppet_module not found

> # hammer -v  puppet-module list
> ID,Name,Author,Version,Uuid
> 3,generic_1,robottelo,0.2.0,2de63c7f-d0fb-4a29-b301-449a52c026d7

> hammer -v content-view puppet-module remove --content-view-id="121" --id="3"
> [ERROR 2017-02-27 12:07:48 Exception] Error: content_view_puppet_module not found
> Couldn't remove puppet module from the content view:
>  Error: content_view_puppet_module not found

Version-Release number of selected component (if applicable):
Satellite 6.2.8 Snap 3.0:
* satellite-6.2.8-1.0.el7sat.noarch
* foreman-1.11.0.66-2.el7sat.noarch
* katello-3.0.0-17.el7sat.noarch

How reproducible:
Always

Steps to Reproduce:
1. Create Content View
2. Create puppet repo with modules
3. Associate puppet module with CV using `hammer content-view puppet-module add`
4. Try to remove using `hammer content-view puppet-module remove --id`

Actual results:
Exception is raised.

Expected results:
Puppet module should removed.

Additional info:

Comment 2 Brad Buckingham 2017-02-28 17:59:17 UTC
Is this a duplicate of bug 1427260?

Comment 3 Stanislav Tkachenko 2017-03-01 07:00:51 UTC
(In reply to Brad Buckingham from comment #2)
> Is this a duplicate of bug 1427260?

I'm not sure how we handle new bugs that are valid for both 6.2 and 6.3 nowadays, so I've cloned 1427260 to track 6.3 status. If it is not correct please close this BZ.

Comment 4 Brad Buckingham 2017-03-01 11:41:14 UTC
Hi Stanislav,

For now, a single bugzilla should be created and proposed for the desired releases (e.g. 6.2.z & 6.3.0).  Once the fix is in the upstream and the bug is committed to a specific 6.2.z, a clone will be created to cover the 2 instances of the bugzilla.  This approach is being taken to minimize some of the overall BZ maintenance and relieve some confusion when folks are looking within bugzilla.

Based on the above, I'll close this one and we can clone it when the time is right.

Thanks!

*** This bug has been marked as a duplicate of bug 1427260 ***


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