Closed Bug 1851012 Opened 10 months ago Closed 10 months ago

Align Search Engine Suggestion Provider behaviour with Desktop

Categories

(Fenix :: Search, enhancement, P3)

All
Android
enhancement

Tracking

(firefox117 wontfix, firefox118 verified, firefox119 verified)

VERIFIED FIXED
119 Branch
Tracking Status
firefox117 --- wontfix
firefox118 --- verified
firefox119 --- verified

People

(Reporter: gl, Assigned: mavduevskiy)

References

Details

(Whiteboard: [fxdroid])

Attachments

(3 files)

For the Search Engine Suggestion Provider, we are currently displaying a search engine suggestion by simply typing a single character as a result of the DEFAULT_CHARACTERS_THRESHOLD = 1.

STR:

  1. Type "m" in the search bar.
  2. See "Search Amazon.com" in the suggestions.

Expected:
We should not see this suggestion.

Testing on Desktop - it appears their threshold is set to at least 2 characters and it performs a startsWith(). This means if we typed "ma" we would not see the "Search Amazon.com" in the suggestions, and it needs to starts with "am" in order see the Amazon search engine suggestion.

I believe we should align the behaviour with desktop. We should do the following:

  1. Increase DEFAULT_CHARACTERS_THRESHOLD to 2
  2. Perform a startsWith instead of contains https://searchfox.org/mozilla-mobile/source/firefox-android/android-components/components/feature/awesomebar/src/main/java/mozilla/components/feature/awesomebar/provider/SearchEngineSuggestionProvider.kt#52.

That makes sense. I agree we should only show the suggestion when we match the first 2+ characters. So to be clear, if I typed "am" the amazon suggestion would show and if I continued and typed the full "amazon.com" the suggestion would still be there. Of course if I hit enter at that point I'd navigate to amazon.com.

Summary: Align Search Engine Suggestion Provider behave with Desktop → Align Search Engine Suggestion Provider behaviour with Desktop
Assignee: nobody → mavduevskiy
Whiteboard: [fxdroid]

Authored by mike a
https://github.com/mozilla-mobile/firefox-android/commit/5389b39020f8308483111d0591395a35cd66fdde
[main] Bug 1851012 – aligned Search Engine Suggestion Provider behaviour with Desktop

Status: NEW → RESOLVED
Closed: 10 months ago
Flags: qe-verify+
Resolution: --- → FIXED
Target Milestone: --- → 119 Branch

For QA, we are blocked on Bug 1851006 landing before this can be tested.

Depends on: 1851006

Is this ready for a v118 backport PR and Beta approval request?

Flags: needinfo?(mavduevskiy)

Let's get a backport PR up, but let's wait until QA has verified this before uplifting?

waiting for the QA approval to open a request

Flags: needinfo?(mavduevskiy)

Verified as fixed on the Fenix Nightly 119.0a1 from 9/11 with Google Pixel 7 Pro ( Android 14) and Motorola Moto G9 plus (Android 11).

Flags: qe-verify+
Attached image search.JPEG

Comment on attachment 9352525 [details] [review]
[mozilla-mobile/firefox-android] Bug 1851012 – aligned Search Engine Suggestion Provider behaviour with Desktop (backport #3455) (#3587)

Beta/Release Uplift Approval Request

  • User impact if declined: It's a small QoL improvement for search, users will get less noise when they start entering the search keyword – search engine suggestions will be shown if 2+ charachters match. Current rules is 1, so any single character in a word bing should add that suggestion to the first search result list.
  • Is this code covered by automated tests?: Yes
  • Has the fix been verified in Nightly?: Yes
  • Needs manual test from QE?: No
  • If yes, steps to reproduce:
  • List of other uplifts needed: None
  • Risk to taking this patch: Low
  • Why is the change risky/not risky? (and alternatives if risky): it's a change for the default value, with to edge cases
  • String changes made/needed:
  • Is Android affected?: Yes
Attachment #9352525 - Flags: approval-mozilla-beta?
Comment on attachment 9352525 [details] [review]
[mozilla-mobile/firefox-android] Bug 1851012 – aligned Search Engine Suggestion Provider behaviour with Desktop (backport #3455) (#3587)

Approved for Fenix 118.0b8
Attachment #9352525 - Flags: approval-mozilla-beta? → approval-mozilla-beta+

Authored by https://github.com/mergify[bot]
https://github.com/mozilla-mobile/firefox-android/commit/796d6baa50525ba3f3e779c51ce335a81b773626
[releases_v118] Bug 1851012 – aligned Search Engine Suggestion Provider behaviour with Desktop (backport #3455) (#3587)

Flags: qe-verify+

Verified as fixed on the latest Beta build (118.0b8).

Device used: Redmi 9C NFC (Android 10).

Marking the ticket as verified for 118 as well.

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

Attachment

General

Created:
Updated:
Size: