Closed Bug 431679 Opened 12 years ago Closed Last year

RESULTS_AS_SITE_QUERY cannot create a result set if NavHistoryQuery attributes used

Categories

(Firefox :: Bookmarks & History, defect)

defect
Not set

Tracking

()

RESOLVED INACTIVE

People

(Reporter: cmtalbert, Unassigned)

References

(Depends on 1 open bug)

Details

Attachments

(4 files)

Attached file the test.
If you set any attributes on the nsINavHistoryQuery object while performing a RESULTS_AS_SITE_QUERY query, your queries seem to succeed but the result set generation seems to fail.  

If you do the query without any nsINavHistoryQuery attributes specified, it works.

I'll attach a test using a very simple query, which can be run with the following command (once you've got a built up test-enabled tree):
 /Users/clint/code/fx-trunk/mozilla/dbg/i386/dist/MinefieldDebug.app/Contents/MacOS/xpcshell -f ~/code/fx-trunk/mozilla/tools/test-harness/xpcshell-simple/head.js -f ~/code/fx-trunk/mozilla/toolkit/components/places/tests/queries/head_queries.js -f ~/code/fx-trunk/mozilla/toolkit/components/places/tests/queries/test_results-as-site-query.js -f ~/code/fx-trunk/mozilla/tools/test-harness/xpcshell-simple/tail.js -f ~/code/fx-trunk/mozilla/tools/test-harness/xpcshell-simple/execute_test.js

What's interesting here is that not all the failures are being captured with asertions either.  I'll attach some logs to show what I mean (otherwise this is going to get unreadable pretty fast).

If you run the test as is, you'll see the WARNING: NS_ENSURE_SUCCESS(rv, rv) failed with result 0x80004005 from here:
http://mxr.mozilla.org/mozilla/source/toolkit/components/places/src/nsNavHistory.cpp#5196
The same behavior occurs if you use RESULTS_AS_DATE_SITE_QUERY. It blows out of the NS_ENSURE_SUCCESS at nsNavHistory.cpp:5196 when its trying to create the result set.  They are likely the same issue since these queries are very similar.

Changing summary to reflect this.
Summary: RESULTS_AS_SITE_QUERY cannot create a result set if NavHistoryQuery attributes used → RESULTS_AS_SITE_QUERY and RESULTS_AS_DATE_SITE_QUERY cannot create a result set if NavHistoryQuery attributes used
(In reply to comment #4)
> The same behavior occurs if you use RESULTS_AS_DATE_SITE_QUERY. It blows out of
> the NS_ENSURE_SUCCESS at nsNavHistory.cpp:5196 when its trying to create the
> result set.  They are likely the same issue since these queries are very
> similar.
> 
> Changing summary to reflect this.
> 
Oops.  Wrong bug.  Apologize for the bug spam.  Please disregard this comment, reverting change to summary.

Summary: RESULTS_AS_SITE_QUERY and RESULTS_AS_DATE_SITE_QUERY cannot create a result set if NavHistoryQuery attributes used → RESULTS_AS_SITE_QUERY cannot create a result set if NavHistoryQuery attributes used
Blocks: 509868
that's because it's trying to apply where clauses to the query, that is a containers query, instead it should propagate the options down to the child queries.
Depends on: 511890
Bug 451915 - move Firefox/Places bugs to Firefox/Bookmarks and History. Remove all bugspam from this move by filtering for the string "places-to-b-and-h".

In Thunderbird 3.0b, you do that as follows:
Tools | Message Filters
Make sure the correct account is selected. Click "New"
Conditions: Body   contains   places-to-b-and-h
Change the action to "Delete Message".
Select "Manually Run" from the dropdown at the top.
Click OK.

Select the filter in the list, make sure "Inbox" is selected at the bottom, and click "Run Now". This should delete all the bugspam. You can then delete the filter.

Gerv
Component: Places → Bookmarks & History
QA Contact: places → bookmarks
Per policy at https://wiki.mozilla.org/Bug_Triage/Projects/Bug_Handling/Bug_Husbandry#Inactive_Bugs. If this bug is not an enhancement request or a bug not present in a supported release of Firefox, then it may be reopened.
Status: NEW → RESOLVED
Closed: Last year
Resolution: --- → INACTIVE
You need to log in before you can comment on or make changes to this bug.