Bug 1573629

Summary: Unclear Error when performing bulk action of Manage Repository Set against Hosts without Content registration
Product: Red Hat Satellite Reporter: Dylan Gross <dgross>
Component: Hosts - ContentAssignee: Samir Jha <sajha>
Status: CLOSED ERRATA QA Contact: Jitendra Yejare <jyejare>
Severity: low Docs Contact:
Priority: unspecified    
Version: 6.3.1CC: ktordeur, sajha, sghai, zhunting
Target Milestone: 6.4.0Keywords: EasyFix, Triaged
Target Release: Unused   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2018-10-16 19:31:36 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:
Attachments:
Description Flags
Verified - Mange repository set success none

Description Dylan Gross 2018-05-01 19:53:20 UTC
Description of problem:

   When trying to perform bulk action "Manage Repository Sets" on Content Hosts, if a Content Host has never registered, it will fail and return an undefined method error:

   NoMethodError: undefined method `uuid' for nil:NilClass


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

   Red Hat Satellite 6.3.1

How reproducible:   Easily, always?


Steps to Reproduce:
1.   Create a Host: WebUI-> Hosts -> All Hosts -> Create Host - But do not actually build one yet or register that host.

2.   Go to WebUI -> Content Hosts and select a number of hosts, including the one just created (which should show as "Never registered" and "Never checked in"

3.   Select "Select Action" -> "Manage Repository Sets" and choose a Repository set and either "Override to Enabled" or "Override to disabled"

Actual results:

The task "Update Contennt Overrides to <content-host>" will fail with an error simply saying "undefined method `uuid' for nil:NilClass"


Expected results:

  The task should still fail, or give a warning, more gracefully with an explanation of the failure rather than the undefined method error.


Additional info:

Comment 4 Samir Jha 2018-06-11 14:59:30 UTC
Created redmine issue http://projects.theforeman.org/issues/23887 from this bug

Comment 5 Satellite Program 2018-06-19 00:20:58 UTC
Moving this bug to POST for triage into Satellite 6 since the upstream issue http://projects.theforeman.org/issues/23887 has been resolved.

Comment 7 Jitendra Yejare 2018-09-10 13:45:02 UTC
Created attachment 1482126 [details]
Verified - Mange repository set success

Verified!

@ Satellite 6.4 snap 20


Steps:

1. Created a Host which is not registered and not checked in.

2. From WebUI -> Content Hosts and selected a number of hosts, including the one just created (which should show as "Never registered" and "Never checked in"

3. Selected "Select Action" -> "Manage Repository Sets" and choose a Repository set and either "Override to Enabled".


Observation:

The task did not fail, and just posted a warning, with an explanation of the failure.

Verification screenshot attached.

Comment 8 Bryan Kearney 2018-10-16 19:31:36 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-2018:2927