Bug 1417807 - remote execution job schedule and details page does not handle search query returning 0 hosts too well
Summary: remote execution job schedule and details page does not handle search query r...
Alias: None
Product: Red Hat Satellite
Classification: Red Hat
Component: Remote Execution
Version: 6.2.6
Hardware: Unspecified
OS: Unspecified
Target Milestone: Unspecified
Assignee: Adam Ruzicka
QA Contact: Ivan Necas
Depends On:
TreeView+ depends on / blocked
Reported: 2017-01-31 06:19 UTC by Jan Hutař
Modified: 2021-03-11 14:56 UTC (History)
7 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Last Closed: 2018-02-21 16:51:07 UTC
Target Upstream Version:

Attachments (Terms of Use)
verification screenshot - preview (38.27 KB, image/png)
2017-08-16 14:55 UTC, Ivan Necas
no flags Details
verification screenshot - job details (33.24 KB, image/png)
2017-08-16 14:56 UTC, Ivan Necas
no flags Details

System ID Private Priority Status Summary Last Updated
Foreman Issue Tracker 18510 0 Normal Closed remote execution job schedule and details page does not handle search query returning 0 hosts too well 2020-04-24 19:16:59 UTC

Description Jan Hutař 2017-01-31 06:19:15 UTC
Description of problem:
With search query matching 0 hosts, remote execution job schedule page:

Preview keeps screen grayed, without preview window and [close] button at all, not error message shown

And details page (this is only for "Update Package - Katello SSH Default through SSH" template):

In "Preview for target", there is "Warning! error during rendering: undefined method 'operatingsystem' for NilClass::Jail (NilClass)" instead of some simple error message

These two pages does not handle search query returning 0 hosts too well

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

How reproducible:

Steps to Reproduce:
1. Schedule remote execution job Monitor -> Jobs -> [Run job] with host
   search query "name ~ such_a_host_does_not_exists"
2. Click icon of "eye" to preview matching hosts
3. Also try to schedule with:
     Job category: Katello
     Job template: Update Package...
   and check "Preview for target" section

Actual results:
On schedule page if you click on preview button, it grays the screen and there is no way back.
On details page it shows template rendering warning

Expected results:
Should be possible to close grayed page and instead of template rendering error there should be informative error message like "No host matches the search query"

Comment 2 Adam Ruzicka 2017-02-15 09:24:56 UTC
Created redmine issue http://projects.theforeman.org/issues/18510 from this bug

Comment 3 pm-sat@redhat.com 2017-02-16 15:10:00 UTC
Upstream bug assigned to aruzicka@redhat.com

Comment 4 pm-sat@redhat.com 2017-02-16 15:10:03 UTC
Upstream bug assigned to aruzicka@redhat.com

Comment 5 pm-sat@redhat.com 2017-02-21 17:09:49 UTC
Moving this bug to POST for triage into Satellite 6 since the upstream issue http://projects.theforeman.org/issues/18510 has been resolved.

Comment 6 Ivan Necas 2017-08-16 14:55:21 UTC
Version Tested: Satellite-6.3 Snap 11

1. run job with search matching 0 hosts
2. see screenshots

Comment 7 Ivan Necas 2017-08-16 14:55:51 UTC
Created attachment 1314229 [details]
verification screenshot - preview

Comment 8 Ivan Necas 2017-08-16 14:56:33 UTC
Created attachment 1314230 [details]
verification screenshot - job details

Comment 9 pm-sat@redhat.com 2018-02-21 16:51: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, 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:0336

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