Closed Bug 1672680 Opened 4 years ago Closed 4 years ago

Search shortcuts can not use IDEOGRAPHIC SPACE(U+3000)

Categories

(Firefox :: Address Bar, defect, P2)

Firefox 83
defect
Points:
2

Tracking

()

VERIFIED FIXED
84 Branch
Iteration:
84.1 - Oct 19 - Nov 01
Tracking Status
firefox-esr78 --- unaffected
firefox82 --- wontfix
firefox83 + verified
firefox84 --- verified

People

(Reporter: open_ffff23, Assigned: adw)

References

(Regression)

Details

(Keywords: regression)

Attachments

(2 files)

Attached image search.png

User Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:83.0) Gecko/20100101 Firefox/83.0

Steps to reproduce:

address bar enter
"b firefox"
"(shortcuts key)(U+3000)(search keyword)"

Actual results:

Searched with the default search engine instead of the "shortcut key" search engine

Expected results:

As well as SPACE(U+0020)

"b firefox"
"b firefox"

Search on the search engine where the shortcut key is registered.

Has STR: --- → yes
Component: Untriaged → Address Bar

Thanks for the report. Do you have a use case where U+3000 is commonly used?

Status: UNCONFIRMED → NEW
Ever confirmed: true
Flags: needinfo?(open_ffff23)

U+3000 is an ideographic space character in CJK. The reporter's screenshot shows that they're using a Japanese build, and U+3000 is the space character you get when you type a space while in Japanese-language mode in your IME. So this is probably actually pretty common for CJK users, and we should fix it. The screenshot appears to show that this used to work in 82, so I'll mark this as a regression.

Severity: -- → S3
Points: --- → 2
Flags: needinfo?(open_ffff23)
Keywords: regression
Priority: -- → P2
Assignee: nobody → adw
Status: NEW → ASSIGNED
Iteration: --- → 84.1 - Oct 19 - Nov 01

Here's the problem (which I created): https://searchfox.org/mozilla-central/rev/ff85081e3b05f89f9a5921b489b6e01ed4a88c25/toolkit/components/places/UnifiedComplete.jsm#1095 So this is a regression due to search mode, which is why it worked in 82.

We (I) should probably audit all calls to startsWith(" ") and similar. We should be using regexps with \s.

Regressed by: 1658964
Has Regression Range: --- → yes

This fixes all the problems created by bug 1658964 and modifies existing tests
so we check a variety of spaces.

[Tracking Requested - why for this release]: keywords/aliases/searchmode malfunction for some locales

Pushed by dwillcoxon@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/7d86a83672c5
Properly handle non-ASCII spaces in search alias and restriction token searches. r=mak
Flags: needinfo?(adw)
Regressions: 1673062
Flags: qe-verify+
Flags: in-testsuite+
Status: ASSIGNED → RESOLVED
Closed: 4 years ago
Resolution: --- → FIXED
Target Milestone: --- → 84 Branch

Confirmed as verified fixed on Windows 10 x64, MacOS 10.14 and Ubuntu 20.04 x64 for Nightly 84.0a1 (20201026092834), en-US and ja versions, after a "b" shortcut was added for Bing in about:preferences#search.

Comment on attachment 9183388 [details]
Bug 1672680 - Properly handle non-ASCII spaces in search alias and restriction token searches.

Beta/Release Uplift Approval Request

  • User impact if declined: CJK users will see a regression where the space character they type with their IME will no longer trigger search shortcuts in the urlbar.
  • Is this code covered by automated tests?: Yes
  • Has the fix been verified in Nightly?: Yes
  • Needs manual test from QE?: Yes
  • If yes, steps to reproduce: This bug has already been verified on 84 in comment 9, but for STR, please see comment 0. You can copy and paste the quoted strings in that comment into the urlbar.
  • List of other uplifts needed: None
  • Risk to taking this patch: Low
  • Why is the change risky/not risky? (and alternatives if risky): This isn't a small patch, but most of it is tests, and the core changes are small. We now have lots of tests for this, and of course we have lots of urlbar tests in general.
  • String changes made/needed:
Flags: needinfo?(adw)
Attachment #9183388 - Flags: approval-mozilla-beta?
QA Whiteboard: [qa-triaged]

Comment on attachment 9183388 [details]
Bug 1672680 - Properly handle non-ASCII spaces in search alias and restriction token searches.

Approved for 83 beta 5, thanks.

Attachment #9183388 - Flags: approval-mozilla-beta? → approval-mozilla-beta+

Confirmed as verified fixed on Beta 83.0b5 (20201027175448) en-US and ja versions, on Windows 10 x64, MacOS 10.14, and Ubuntu 20.04 x64.

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

Attachment

General

Creator:
Created:
Updated:
Size: