Bug 674347

Summary: EXT Bug URL queries are broken
Product: [Community] Bugzilla Reporter: Chris Ward <cward>
Component: Bugzilla GeneralAssignee: Simon Green <sgreen>
Status: CLOSED UPSTREAM QA Contact:
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 3.6CC: dmair, ebaak, jwest, nelhawar, sgreen
Target Milestone: ---Keywords: FutureFeature, Reopened
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Enhancement
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2011-11-30 02:41:24 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:

Description Chris Ward 2011-02-01 15:23:21 UTC
Description of problem:


Queries with 'ext bug url ...'  are broken.

For example, using this query which looks for ext bug url 'access.redhat.com':

http://hurl.test.redhat.com/eLG2rh

some of the bugs, eg, the top most bug #118490 DO NOT actually contain access.redhat.com in their URL.

Comment 1 Jeremy West 2011-02-01 15:29:20 UTC
It appears that the query is only broken when other external bugs are attached and have a greater index than the red hat portal case #.

Comment 2 Noura El hawary 2011-02-02 11:14:14 UTC
Hi,

When I took a look at the query you have ,, you got thing in the boolean chart:

External Bug Url : does not contain the string: access.redhat.com 

so it is not really looking for the bugs with this external bugzilla.


Noura

Comment 3 Chris Ward 2011-02-02 11:59:56 UTC
Oops! I explained the example incorrectly. Let me try again.

In the query above, i've included the boolean 

'External Bug Url' 'does not contain the string' 'access.redhat.com'

But it matches the bug #297531, which DOES have access.redhat.com Ext bug url.

Comment 4 Simon Green 2011-11-20 23:00:33 UTC
(In reply to comment #3)
> Oops! I explained the example incorrectly. Let me try again.
> 
> In the query above, i've included the boolean 
> 
> 'External Bug Url' 'does not contain the string' 'access.redhat.com'
> 
> But it matches the bug #297531, which DOES have access.redhat.com Ext bug url.

It also has an "'External Bug Url' that 'does not contain the string' 'access.redhat.com'" (the Samba external tracker).

This is expected behaviour.

  -- simon

Comment 5 Chris Ward 2011-11-21 15:01:43 UTC
i believe this query

https://bugzilla.redhat.com/buglist.cgi?query_format=advanced&field0-0-0=external_bugzilla.url&bug_status=NEW&type0-0-0=notsubstring&value0-0-0=access.redhat.com&product=Red%20Hat%20Enterprise%20Linux%206

should result in a list of (...Status:NEW, Prod:Red Hat...) bugs which 
DO NOT CONTAIN THE STRING 'access.redhat.com' in an External Bug URL;
ie, do not have customer tickets attached.

Notice, however, for example, (first bug) bz#471953 shows up in the 
results. This bug has 3 ext. bzs attached which all link to access.redhat.com

If i'm using search incorrectly, please let me know how i can do a search that
definitely finds only those bugs which DO NOT link to external bugzillas that have url access.redhat.com in them. (eg, i want to find all bugs that are not linked to customer tickets)

p.s. ... please don't close bugs without folks agreeing its the proper action ....

Comment 6 Chris Ward 2011-11-21 15:15:11 UTC
Looking back at comment #3, i can reproduce.

https://bugzilla.redhat.com/buglist.cgi?query_format=advanced&field0-0-0=external_bugzilla.url&type0-0-0=notsubstring&value0-0-0=access.redhat.com&product=Red%20Hat%20Enterprise%20Linux%205

"
Product: Red Hat Enterprise Linux 5 
External Bug URL: (does not contain the string) access.redhat.com
"



This query should find only bugs that DO NOT have ext. bz's with access.redhat.com in their url; but it finds https://bugzilla.redhat.com/show_bug.cgi?id=297531
which does have access.redhat.com ext bz attached.

I guess i'm a little confused by your comment #4 and close.

If things worked the way i would expect, this bug would not show up in the results list... since it DOES have an ext. bz with access.redhat.com url attached.

Comment 7 Simon Green 2011-11-21 23:55:26 UTC
(In reply to comment #5)
> i believe this query
> 
> https://bugzilla.redhat.com/buglist.cgi?query_format=advanced&field0-0-0=external_bugzilla.url&bug_status=NEW&type0-0-0=notsubstring&value0-0-0=access.redhat.com&product=Red%20Hat%20Enterprise%20Linux%206
> 
> should result in a list of (...Status:NEW, Prod:Red Hat...) bugs which 
> DO NOT CONTAIN THE STRING 'access.redhat.com' in an External Bug URL;
> ie, do not have customer tickets attached.
> 
> Notice, however, for example, (first bug) bz#471953 shows up in the 
> results. This bug has 3 ext. bzs attached which all link to access.redhat.com

Bug 471953 also has one external bugzilla that matches "does not contain the string access.redhat.com" (it contains the string 'kbase.redhat.com'), and that is what your query is being interpreted as. As per comment #4, this is the correct behaviour of Red Hat Bugzilla.


> If i'm using search incorrectly, please let me know how i can do a search that
> definitely finds only those bugs which DO NOT link to external bugzillas that
> have url access.redhat.com in them. (eg, i want to find all bugs that are not
> linked to customer tickets)

AFAIK, there isn't a way to perform such a query.
 
> p.s. ... please don't close bugs without folks agreeing its the proper action
> ....

You are free to reopen the bug you have more comment to add, or thinks it requires further action.

(In reply to comment #6)
> External Bug URL: (does not contain the string) access.redhat.com"
> 
> This query should find only bugs that DO NOT have ext. bz's with
> access.redhat.com in their url; but it finds
> https://bugzilla.redhat.com/show_bug.cgi?id=297531
> which does have access.redhat.com ext bz attached.

That is incorrect. This search will find bugs with an external tracker URL that does not contain the string access.redhat.com. In other words, it will find bugs that have some other external tracker.

> If things worked the way i would expect, this bug would not show up in the
> results list... since it DOES have an ext. bz with access.redhat.com url
> attached.

Like with the above example, this bug has an external tracker URL of bugzilla.samba.org, which meets the criteria of "does not contain the string access.redhat.com"

  -- simon

Comment 8 Chris Ward 2011-11-22 09:58:52 UTC
haha; you seriously closed it again! haha. 

I'll turn this into a RFE then... being able to accurately search for bugs that are or are not connected to Customer tickets is VERY IMPORTANT for us in QE.

Comment 9 Chris Ward 2011-11-22 10:01:49 UTC
Previously, all i had to do was 'Issue Tracker' 'Not Null' to find bugs which have customer tickets attached or 'is Null' to find bugs which do not have customer tickets attached.

Comment 10 Simon Green 2011-11-30 02:41:24 UTC
(In reply to comment #8)
> I'll turn this into a RFE then... being able to accurately search for bugs that
> are or are not connected to Customer tickets is VERY IMPORTANT for us in QE.

This will be fixed when we move to Bugzilla 4.2 (no ETA at this stage on when it will be released upstream or when we will start using it). From the Bugzilla 4.1.1 release notes:

"Boolean charts now work sensibly for almost all fields. For example, searching for “CC is not equal to” now finds bugs where that user is not CC’ed, instead of all bugs that have at least one CC who isn’t that user."

> haha; you seriously closed it again! haha. 

This change will fix the problem you reported in comment #3. Red Hat is *very* unlikely to to make this change outside of upstream's release cycle, so marking as CLOSED/UPSTREAM.