Skip to content

fix: don't show empty autofill popup - #52262

Merged
jkleinsc merged 2 commits into
mainfrom
nmg/dont-show-entryless-autofill-popup
Jul 13, 2026
Merged

jkleinsc merged 2 commits into
mainfrom
nmg/dont-show-entryless-autofill-popup

Conversation

@nmggithub

@nmggithub nmggithub commented Jul 4, 2026 •

Copy link
Copy Markdown
Contributor

Description of Change

Resolves #52260. This was written with the help of GPT-5.5 with the Codex CLI. Not sure if this needs release notes as it's unclear how impactful this bug has been.

Checklist

Release Notes

Notes: Fixed unnecessary autofill popup creation for fields without datalist suggestions, which could cause input latency on macOS.

@electron-cation electron-cation Bot added the new-pr 🌱 PR opened recently label Jul 4, 2026
@nikwen

nikwen commented Jul 4, 2026

Copy link
Copy Markdown
Member

Not sure if this needs release notes as it's unclear how impactful this bug has been.

Let's add some, focusing on the performance optimization. :)

@nikwen nikwen added semver/patch backwards-compatible bug fixes target/41-x-y PR should also be added to the "41-x-y" branch. target/42-x-y PR should also be added to the "42-x-y" branch. target/43-x-y PR should also be added to the "43-x-y" branch. target/44-x-y PR should also be added to the "44-x-y" branch. labels Jul 4, 2026
@electron-cation electron-cation Bot removed the new-pr 🌱 PR opened recently label Jul 5, 2026
A hostile renderer could send values without matching labels and crash
the browser process via out-of-range label access in label_at(). Also
route the hide through HideAutofillPopup() for consistency and add
comments explaining the guards.
@MarshallOfSound

Copy link
Copy Markdown
Member

Pushed a small commit on top — routes the hide through HideAutofillPopup() for consistency, and also rejects mismatched values/labels at the mojo boundary since label_at() is an unchecked .at() and a compromised renderer sending values without labels could crash the browser process.

Also verified the resulting patch locally on macOS 26: repro'd the issue first with emulated IME inputs (Input.imeSetComposition via the debugger API) — the browser main thread was stuck constructing NSWindows on every composition keystroke — and with this patch that drops to zero window churn and zero main-thread stalls, while datalist popups still show and accept suggestions via ArrowDown+Enter. Nice find 🎉

@nmggithub

nmggithub commented Jul 6, 2026 •

Copy link
Copy Markdown
Contributor Author

Nice find 🎉

Thanks, although I can't take too much credit for it. @hirorocky, the original issue reporter, is the one who found it!

@jkleinsc
jkleinsc merged commit 8ee6d5e into main Jul 13, 2026
78 checks passed
@release-clerk

release-clerk Bot commented Jul 13, 2026

Copy link
Copy Markdown

Release Notes Persisted

Fixed unnecessary autofill popup creation for fields without datalist suggestions, which could cause input latency on macOS.

@trop

trop Bot commented Jul 13, 2026

Copy link
Copy Markdown
Contributor

I have automatically backported this PR to "44-x-y", please check out #52318

@trop

trop Bot commented Jul 13, 2026

Copy link
Copy Markdown
Contributor

I have automatically backported this PR to "42-x-y", please check out #52319

@trop trop Bot added in-flight/42-x-y and removed target/44-x-y PR should also be added to the "44-x-y" branch. labels Jul 13, 2026
@trop

trop Bot commented Jul 13, 2026

Copy link
Copy Markdown
Contributor

I have automatically backported this PR to "41-x-y", please check out #52320

@trop

trop Bot commented Jul 13, 2026

Copy link
Copy Markdown
Contributor

I have automatically backported this PR to "43-x-y", please check out #52321

@trop trop Bot removed the target/42-x-y PR should also be added to the "42-x-y" branch. label Jul 13, 2026
@trop trop Bot added in-flight/41-x-y in-flight/43-x-y merged/43-x-y PR was merged to the "43-x-y" branch. merged/41-x-y PR was merged to the "41-x-y" branch. merged/42-x-y PR was merged to the "42-x-y" branch. merged/44-x-y PR was merged to the "44-x-y" branch. and removed target/41-x-y PR should also be added to the "41-x-y" branch. target/43-x-y PR should also be added to the "43-x-y" branch. in-flight/43-x-y in-flight/41-x-y in-flight/42-x-y in-flight/44-x-y labels Jul 13, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

merged/41-x-y PR was merged to the "41-x-y" branch. merged/42-x-y PR was merged to the "42-x-y" branch. merged/43-x-y PR was merged to the "43-x-y" branch. merged/44-x-y PR was merged to the "44-x-y" branch. semver/patch backwards-compatible bug fixes

Projects

None yet

4 participants