Bug 864362 - name_autocomplete raising exception while adding system to system group
name_autocomplete raising exception while adding system to system group
Status: CLOSED UPSTREAM
Product: Red Hat Satellite 6
Classification: Red Hat
Component: WebUI (Show other bugs)
6.0.0
Unspecified Unspecified
unspecified Severity high (vote)
: Unspecified
: --
Assigned To: Tom McKay
Sachin Ghai
: Triaged
: 839286 (view as bug list)
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2012-10-09 04:51 EDT by Sachin Ghai
Modified: 2013-09-19 14:15 EDT (History)
3 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2013-09-19 14:15:29 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)
exception raised when you add system to sys group. if sysname is 'test' then add it like 'test (' (163.20 KB, image/png)
2012-10-09 04:51 EDT, Sachin Ghai
no flags Details
notice name autocomplete shows the system name with date/time of registration (30.58 KB, image/png)
2012-10-09 04:54 EDT, Sachin Ghai
no flags Details
add sys to sys group with given patterns (37.62 KB, image/png)
2012-10-09 06:05 EDT, Sachin Ghai
no flags Details

  None (edit)
Description Sachin Ghai 2012-10-09 04:51:49 EDT
Created attachment 623999 [details]
exception raised when you add system to sys group. if sysname is 'test' then add it like  'test ('

Description of problem:
When you add a system to system group, UI auto complete the system name with "date of registration"

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

katello-glue-candlepin-1.1.13-1.git.94.c7b071c.el6_3.noarch
katello-configure-1.1.10-1.git.48.b44a09b.el6_3.noarch
katello-qpid-broker-key-pair-1.0-1.noarch
katello-all-1.1.13-1.git.94.c7b071c.el6_3.noarch
katello-cli-1.1.9-1.git.87.d650484.el6_3.noarch
katello-cli-common-1.1.9-1.git.87.d650484.el6_3.noarch
katello-certs-tools-1.1.8-1.el6.noarch
katello-common-1.1.13-1.git.94.c7b071c.el6_3.noarch
katello-selinux-1.1.2-1.el6.noarch
katello-candlepin-cert-key-pair-1.0-1.noarch
katello-glue-pulp-1.1.13-1.git.94.c7b071c.el6_3.noarch
katello-1.1.13-1.git.94.c7b071c.el6_3.noarch
katello-glue-foreman-1.1.13-1.git.94.c7b071c.el6_3.noarch
katello-qpid-client-key-pair-1.0-1.noarch


How reproducible:
always

Steps to Reproduce:
1. register a system 'test'
2. create a system group
3. when you add system 'test' to system group, notice the 'autocomplete' name with the date/time of registration
4. try add the sys name like 'test ('
  
Actual results:
exception raised on UI

Expected results:
no exception should be raised on UI. 

Additional info:
Comment 1 Sachin Ghai 2012-10-09 04:54:23 EDT
Created attachment 624000 [details]
notice name autocomplete shows the system name with date/time of registration
Comment 2 Sachin Ghai 2012-10-09 04:56:30 EDT
snippet from production.log:

--
[ERROR: 2012-10-09 11:21:04 #29308] Rendering 500:500 : {"error":"SearchPhaseExecutionException[Failed to execute phase [query], total failure; shardFailures {[K1N6C5GcRhmbR_le1WIDdg][katello_system][0]: SearchParseException[[katello_system][0]: from[-1],size[-1]: Parse Failure [Failed to parse source [{\"filter\":{\"terms\":{\"environment_id\":[2,1]}},\"query\":{\"query_string\":{\"query\":\"name_autocomplete:mysys (\"}}}]]]; nested: QueryParsingException[[katello_system] Failed to parse query [name_autocomplete:mysys (]]; nested: ParseException[Cannot parse 'name_autocomplete:mysys (': Encountered \"<EOF>\" at line 1, column 25.\nWas expecting one of:\n    <NOT> ...\n    \"+\" ...\n    \"-\" ...\n    \"(\" ...\n    \"*\" ...\n    <QUOTED> ...\n    <TERM> ...\n    <PREFIXTERM> ...\n    <WILDTERM> ...\n    \"[\" ...\n    \"{\" ...\n    <NUMBER> ...\n    <TERM> ...\n    \"*\" ...\n    ]; nested:
--
Comment 4 Sachin Ghai 2012-10-09 06:03:40 EDT
Similar issue found in latest CFSE puddle:

katello-1.1.12-14.el6cf.noarch

when you add system to system group with any of following sequences in 'Add text widget' then a exception raised on UI:

systemname (
systemname )
systemname ()
systemname !

Please see the attachment for exact location on UI.
Comment 5 Sachin Ghai 2012-10-09 06:05:08 EDT
Created attachment 624015 [details]
add sys to sys group with given patterns
Comment 6 Mike McCune 2012-10-09 17:11:48 EDT
ugly, but not a blocker
Comment 7 Tom McKay 2012-10-10 08:38:59 EDT
Already have pull-request to fix. If it's ASSIGNED state, that means I'm active on it.
Comment 8 Tom McKay 2012-10-10 10:58:19 EDT
  Branch: refs/heads/master
  Home:   https://github.com/Katello/katello
  Commit: 4e8626001d4df16ca9641392b9793fe4a0e96560
      https://github.com/Katello/katello/commit/4e8626001d4df16ca9641392b9793fe4a0e96560
  Author: Tom McKay <thomasmckay@redhat.com>
  Date:   2012-10-09 (Tue, 09 Oct 2012)
Comment 9 Marek Hulan 2012-12-18 09:36:44 EST
*** Bug 839286 has been marked as a duplicate of this bug. ***
Comment 10 Mike McCune 2013-09-19 14:15:29 EDT
These bugs have been resolved in upstream projects for a period of months so I'm mass-closing them as CLOSED:UPSTREAM.  If this is a mistake feel free to re-open.

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