Project

General

Profile

Bug #30556

'Host - compare content hosts packages' report fails with error 'undefined method '#first' for NilClass'

Added by Tomer Brisker about 2 months ago. Updated 13 days ago.

Status:
Closed
Priority:
Normal
Assignee:
Category:
Reporting
Target version:
-
Difficulty:
Triaged:
No
Bugzilla link:
Fixed in Releases:
Found in Releases:

Description

Cloned from https://bugzilla.redhat.com/show_bug.cgi?id=1860351

Description of problem: Generating 'Host - compare content hosts packages' using wrong host fails with error "undefined method '#first' for NilClass::Jail (NilClass)" in WebUI

Hammer also fails with different error
#hammer report-template generate --inputs "Host 1 = host1.example.local,Host 2 = wrong.host.local" --name 'Host - compare content hosts packages'
Unrecognized status code :internal_error

Production log:
2020-07-24T16:25:53 [I|app|16e87c8c] Started POST "/api/report_templates/243/generate" for 127.0.0.1 at 2020-07-24 16:25:53 +0530
2020-07-24T16:25:53 [I|app|16e87c8c] Processing by Api::V2::ReportTemplatesController#generate as JSON
2020-07-24T16:25:53 [I|app|16e87c8c] Parameters: {"input_values"=>"[FILTERED]", "apiv"=>"v2", "id"=>"243", "report_template"=>{}}
2020-07-24T16:25:53 [I|app|16e87c8c] Authorized user admin(Admin User)
2020-07-24T16:25:53 [W|app|16e87c8c] Scoped order is ignored, it's forced to be batch order.
2020-07-24T16:25:53 [W|app|16e87c8c] Scoped order is ignored, it's forced to be batch order.
2020-07-24T16:25:54 [W|app|16e87c8c] Action failed
2020-07-24T16:25:54 [I|app|16e87c8c] Rendering api/v2/errors/standard_error.json.rabl within api/v2/layouts/error_layout
2020-07-24T16:25:54 [I|app|16e87c8c] Rendered api/v2/errors/standard_error.json.rabl within api/v2/layouts/error_layout (Duration: 14.6ms | Allocations: 6560)
2020-07-24T16:25:54 [I|app|16e87c8c] Completed 500 Internal Server Error in 434ms (Views: 21.5ms | ActiveRecord: 69.9ms | Allocations: 198510)

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

How reproducible: Always

Actual results: raise and error

Expected results: Should fail with valid error message

Additional info:
[root@dhcp130-171 foreman]# rpm -qa satellite
satellite-6.8.0-0.7.beta.el7sat.noarch
[root@dhcp130-171 foreman]# rpm -qa foreman
foreman-2.1.0.1-1.el7sat.noarch
[root@dhcp130-171 foreman]# rpm -qa katello
katello-3.16.0-0.4.rc4.el7sat.noarch

Associated revisions

Revision 2a92b54c (diff)
Added by Shira Maximov 28 days ago

Fixes #30556 - Get an accurate err for invalid hosts in report (#7897)

History

#1 Updated by Tomer Brisker about 2 months ago

  • Priority changed from High to Normal
  • Category changed from Statistics to Reporting

#2 Updated by The Foreman Bot about 1 month ago

  • Assignee set to Shira Maximov
  • Status changed from New to Ready For Testing
  • Pull request https://github.com/theforeman/foreman/pull/7897 added

#3 Updated by The Foreman Bot 28 days ago

  • Fixed in Releases 2.3.0 added

#4 Updated by Shira Maximov 28 days ago

  • Status changed from Ready For Testing to Closed

#5 Updated by Tomer Brisker 28 days ago

  • Fixed in Releases 2.2.0 added
  • Fixed in Releases deleted (2.3.0)

#6 Updated by The Foreman Bot 13 days ago

  • Pull request https://github.com/theforeman/foreman/pull/7975 added

Also available in: Atom PDF