Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.
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 1469148

Summary: Filtering user/user groups/capsules/compute profiles/compute resources with invalid field shows Internal Error
Product: Red Hat Satellite Reporter: Nikhil Kathole <nkathole>
Component: SearchAssignee: Tomer Brisker <tbrisker>
Status: CLOSED ERRATA QA Contact: Nikhil Kathole <nkathole>
Severity: medium Docs Contact:
Priority: unspecified    
Version: 6.3.0CC: mhulan, nkathole, sghai, sgraessl, tbrisker
Target Milestone: Unspecified   
Target Release: Unused   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: foreman-1.15.3 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2018-02-21 16:49:54 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
screenshot of UI
none
log in production.log file
none
screenshot of UI
none
log in production.log file none

Description Nikhil Kathole 2017-07-10 13:47:39 UTC
Description of problem: We were trying to filter user/user groups/capsules/compute profiles/ compute resources. In filter, when we added field which was not present in list( any_string=any_string), it returned an error "Something went wrong" and log file had 500 Internal Server Error.



Version-Release number of selected component (if applicable): satellite 6.3.0 snap 6.0


How reproducible: always


Steps to Reproduce:
1. Navigate to Administer-> user/user groups/capsules/compute profiles/compute resources ( producible at any)
2. Filter as any_string=any_string 


Actual results:
Shows the error as "Something went wrong" and the log file /var/log/foreman/production.log shows 

Rendered common/500.html.erb within layouts/application (3.7ms)
2017-07-10 09:32:35 7d7c37e3 [app] [I]   Rendered layouts/_application_content.html.erb (0.5ms)
2017-07-10 09:32:35 7d7c37e3 [app] [I]   Rendered layouts/base.html.erb (2.6ms)
2017-07-10 09:32:35 7d7c37e3 [app] [I] Completed 500 Internal Server Error


Expected results: Error should be handled showing alert as "Field not recognised for searching" as happens in filtering hosts(Host -> All Hosts - > Filter ).


Additional info:

Comment 1 Nikhil Kathole 2017-07-10 13:52:37 UTC
Created attachment 1295840 [details]
screenshot of UI

Comment 2 Tomer Brisker 2017-07-11 09:22:37 UTC
could you please attach the entire section of production log, starting with the GET request until the 500 error, with debug enabled? I could not reproduce this upstream.

Comment 3 Nikhil Kathole 2017-07-11 09:33:43 UTC
Created attachment 1296144 [details]
log in production.log file

Comment 4 Tomer Brisker 2017-07-11 11:28:42 UTC
Created redmine issue http://projects.theforeman.org/issues/20272 from this bug

Comment 6 Satellite Program 2017-07-11 12:14:49 UTC
Upstream bug assigned to tbrisker

Comment 7 Satellite Program 2017-07-11 12:14:52 UTC
Upstream bug assigned to tbrisker

Comment 8 Satellite Program 2017-07-11 18:15:18 UTC
Moving this bug to POST for triage into Satellite 6 since the upstream issue http://projects.theforeman.org/issues/20272 has been resolved.

Comment 10 Nikhil Kathole 2017-08-14 05:48:59 UTC
VERIFIED

Version Tested:
Satellite-6.3 Snap 11

Error is properly handled showing notification alert as "Invalid search query :Field not recognised for searching" while filtering user/user groups/capsules/compute profiles/compute resources with invalid search.

Comment 11 Nikhil Kathole 2017-08-14 05:49:40 UTC
Created attachment 1312950 [details]
screenshot of UI

Comment 12 Nikhil Kathole 2017-08-14 05:52:27 UTC
Created attachment 1312951 [details]
log in production.log file

Comment 13 Satellite Program 2018-02-21 16:49:54 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