New issue
Advanced search Search tips

Issue 838897 link

Starred by 1 user

Issue metadata

Status: Fixed
Owner:
Closed: May 2018
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: ----
Pri: 2
Type: Bug



Sign in to add a comment

Autocomplete predictors are not removed correctly when deleting individual urls

Project Member Reported by dullweber@chromium.org, May 2 2018

Issue description

Chrome Version: 68.0.3409.2 
OS: Linux

What steps will reproduce the problem?
(1) visit facebook.com
(2) go to chrome://history and delete the facebook.com entry
(3) check chrome://predictors

What is the expected result?
chrome://predictors should have removed entries related to facebook.com

What happens instead?
chrome://predictors still contains many entries related to facebook.com with urls that I have never visited. 
All of them have a confidence of 0. Some have a hitcount of 1 but most have 0.

Is it possible to improve the cleanup?
 
Cc: lizeb@chromium.org alexilin@chromium.org mattcary@chromium.org
Components: UI>Browser>History
Explicitly add some folks who might know about chrome://predictors.

(By the way, is there a component I should be using here?)
Cc: -alexilin@chromium.org
Owner: alexilin@chromium.org
Status: Assigned (was: Untriaged)
Am I right that you're talking about the "Autocomplete Action Predictor" tab in chrome://predictors? I believe that the "Resource Prefetch Predictor" db correctly deletes entries that were deleted from the history.
I'll take a look at the autocomplete predictor.

We don't have a special bug component for predictors.
Yes, this only affects autocomplete predictors and not resource prefetch predictors.
Okay, I know what's going on. 

The AutocompleteActionPredictor actually implements HistoryServiceObserver::OnURLsDeleted() but the predictor deletes only the rows that fully match URLs that were removed from the history. However, the autocomplete predictor's database is also populated by autocomplete results that are related to the page the user just visited but don't match any entry in the history.

So, for example, when I type "facebook.com" in the omnibox, the database gets the following URLs:
http://www.facebook.com/
https://www.google.fr/search?q=facebook.com&oq=facebook.com&aqs=chrome..5j61i53j1l4&sourceid=chrome&ie=UTF-8
http://facebook.com/device
http://facebook.com/help/delete_account
http://www.facebook.com/recover.php

Later when I'm deleting the http://www.facebook.com/ entry from the history this URL will be also deleted from the autocomplete database, but all other URLs that I've never visited will stay.

I agree this is a problem because this way we reveal what the user has typed in the omnibox.

The AutocompletePredictor already has a function that deletes all entries that aren't present in the history. But this function is currently called only during the startup. I think we should just call it every time after the user deletes something in the history.

I'll go ahead and send a CL.
Project Member

Comment 5 by bugdroid1@chromium.org, May 14 2018

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/c2a4bcefb464c1e9b1885a442b7017b1e87afc6b

commit c2a4bcefb464c1e9b1885a442b7017b1e87afc6b
Author: Alexandr Ilin <alexilin@chromium.org>
Date: Mon May 14 15:56:55 2018

predictors: Clean up the predictor db after deleting individual urls

The autocomplete predictor database contains entries related to a page the user
has visited even after this page was removed from the history. These entries
are cleaned up after only the startup. This CL adds this clean up after every
removal from history.

Bug:  838897 
Change-Id: Ia56de868cddf8bb0a28d288265b884c0e67458d5
Reviewed-on: https://chromium-review.googlesource.com/1043868
Commit-Queue: Alexandr Ilin <alexilin@chromium.org>
Reviewed-by: Benoit L <lizeb@chromium.org>
Reviewed-by: Christian Dullweber <dullweber@chromium.org>
Cr-Commit-Position: refs/heads/master@{#558326}
[modify] https://crrev.com/c2a4bcefb464c1e9b1885a442b7017b1e87afc6b/chrome/browser/predictors/autocomplete_action_predictor.cc
[modify] https://crrev.com/c2a4bcefb464c1e9b1885a442b7017b1e87afc6b/chrome/browser/predictors/autocomplete_action_predictor.h
[modify] https://crrev.com/c2a4bcefb464c1e9b1885a442b7017b1e87afc6b/chrome/browser/predictors/autocomplete_action_predictor_unittest.cc

Status: Fixed (was: Assigned)

Sign in to add a comment