Closed Bug 1770176 Opened 2 years ago Closed 2 years ago

Adaptive autofill overwrite effect in case of http SearchString

Categories

(Firefox :: Address Bar, defect, P1)

Firefox 102
Desktop
All
defect
Points:
3

Tracking

()

VERIFIED FIXED
102 Branch
Tracking Status
firefox102 --- verified

People

(Reporter: vlucaci, Assigned: daisuke)

References

(Blocks 1 open bug)

Details

Attachments

(3 files)

Attached video 2022-05-19 16-11-08.mkv

Affected versions

  • 102.0a1(20220518214245)

Affected platforms

  • macOS 11
  • Windows 11
  • Windows 10
  • Ubuntu 20

Steps to reproduce

  1. Launch Firefox.
  2. Go to this http page
  3. Open a new tab and close the page from step 2.
  4. In the new tab , write "ht"

Expected result

  • The Autofill should not give any suggestions to the http page page from history , after inputting only two of the following letters "ht".

Actual result

  • The http page is autofilled as soon as the user only inputs "ht"

Seems that the behavior originally in description has been fixed by bug 1769585. Reusing this bug for the overwrite effect in case of http (see attachment), although this also might be invalid depending on bug 1770164 resolution.

Summary: Autofill is done based on incomplete searchString for http websites → Adaptive autofill overwrite effect in case of http SearchString
Has STR: --- → yes

Here's the video on Google Drive, which makes it easier to watch for me: https://drive.google.com/file/d/1uET_DwLe332mzkTDHo5NWs1kpzQN-HNu/view?usp=sharing

This is a weird one. I can reproduce with these STR:

  1. Enable adaptive history autofill
  2. Paste http://info.cern.ch/ in the urlbar and press enter
  3. Open a new tab and close the tab from the previous step
  4. Type http and pick the URL result from step 1
  5. Type http again

At this point "http.cern.ch/" autofills, which is wrong, but the heuristic result's URL is http://info.cern.ch/, which is right. So when you press enter, you visit the correct URL.

Clearly we're not handling prefixes and/or fixup_url() in the SQL correctly.

Severity: S3 → S2
Points: --- → 3
Priority: -- → P1

I could reproduce this issue too. I will take a look at this.

Assignee: nobody → daisuke
Status: NEW → ASSIGNED

Hi Drew.
I found the reason for the issue of your STR, and could fix.
And, one more thing. If we input http://, it can't autofill by another reason below.
https://searchfox.org/mozilla-central/rev/a688eb56e8f69acef88bbad1b224b5bd70dba842/browser/components/urlbar/UrlbarProviderAutofill.jsm#293-300
Here, I want to ask you, I think we better make autofill available even if user's input is "http://" at least for adaptive history autofill, but what do you think?

Flags: needinfo?(adw)

Yeah, I agree, it should be possible to use a prefix (or part of a prefix) for adaptive history autofill. We should still require a non-empty search string for origin and URL autofill though. We'll need to modify that early return you linked, but we'll need to be careful not to try to do origin and URL autofill if the search string is empty.

Flags: needinfo?(adw)

Okay, thank you so much!

Pushed by dakatsuka.birchill@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/725965204d39
Autofill with fixed_url when user's input matches with it. r=adw
https://hg.mozilla.org/integration/autoland/rev/44a4d0fa1095
Make autofilling available when user's input expresses a protocol like 'http://'. r=adw
Status: ASSIGNED → RESOLVED
Closed: 2 years ago
Resolution: --- → FIXED
Target Milestone: --- → 102 Branch
Flags: qe-verify+

Verified as fixed on Firefox 102 beta 4 and latest Nightly 103.0a1 under Win 10 64-bit, Ubuntu 22.04 and OSX 12.

Status: RESOLVED → VERIFIED
Flags: qe-verify+
See Also: → 1774885
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: