Race condition in autocompletion when there's text after the completed word
Categories
(DevTools :: Console, defect, P2)
Tracking
(firefox78 fixed)
Tracking | Status | |
---|---|---|
firefox78 | --- | fixed |
People
(Reporter: julienw, Assigned: nchevobbe)
References
Details
Attachments
(1 file)
I found another occurrence of the problem described and fixed in bug 1595068 and bug 1600680.
STR:
- open the console.
- Start to enter
f(null)
, but press enter before the end of "null", when the autocomplete appears.
=>nnull
is added most of the time.
The same happens with other things. For example I tried withwindow
too (wwindow
is added). This also seems to happen more easily when replacing the parameter instead of adding it.
Assignee | ||
Comment 1•4 years ago
|
||
Thanks for the report Julien, I do reproduce this, let's see what's happening
Assignee | ||
Updated•4 years ago
|
Assignee | ||
Comment 2•4 years ago
|
||
When the completed word has character after it,
we don't display the completion text (the grey
text that indicates what will be added to the
input if you press enter), and we keep the autocomplete
popup open, even if there's only one item in it.
But in the code where we're mitigating races on
autocompletion, we were having a check on the completionText
existence, which would not cover the cases where the
popup is shown but not the completion text.
By changing the condition in the if, the issue is fixed.
A test case is added to ensure this works as expected
and that we don't regress.
Assignee | ||
Updated•4 years ago
|
Pushed by nchevobbe@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/39fb36ae22fe Fix race condition in console autocomplete. r=Honza.
Comment 4•4 years ago
|
||
bugherder |
Description
•