Closed
Bug 1356758
Opened 4 years ago
Closed 4 years ago
Intermittent browser/modules/test/browser/browser_UsageTelemetry_urlbar.js | Test timed out -
Categories
(Firefox :: General, defect, P1)
Firefox
General
Tracking
()
RESOLVED
FIXED
Firefox 58
People
(Reporter: intermittent-bug-filer, Assigned: mak)
References
Details
(Keywords: intermittent-failure, Whiteboard: [stockwell fixed][fxsearch])
Attachments
(2 files)
Filed by: philringnalda [at] gmail.com https://treeherder.mozilla.org/logviewer.html#?job_id=91836602&repo=autoland https://queue.taskcluster.net/v1/task/DFa2XsKGQgyk6CN3YNdUmQ/runs/0/artifacts/public/logs/live_backing.log
| Comment hidden (Intermittent Failures Robot) |
| Comment hidden (Intermittent Failures Robot) |
Comment 3•4 years ago
|
||
this test is failing very frequently, mostly linux32 debug. here is the test: https://dxr.mozilla.org/mozilla-central/source/browser/modules/test/browser/browser_UsageTelemetry_urlbar.js?q=path%3Abrowser_UsageTelemetry_urlbar.js&redirect_type=single I noticed this was filed 5 days ago and 5 days ago a change from bug 1334615 was landed: https://hg.mozilla.org/mozilla-central/rev/dd703291b11a Most likely the changes are related to the failure. :adw, can you take a look at this? With 29 failures yesterday, I would be inclined to disable this test (linux32/debug) in the short term or set this as a higher priority to reduce the pain.
Flags: needinfo?(adw)
Whiteboard: [stockwell needswork]
Comment 4•4 years ago
|
||
I probably won't be able to look at this very soon.
Assignee: nobody → adw
Status: NEW → ASSIGNED
Flags: needinfo?(adw)
Comment 5•4 years ago
|
||
thanks :adw! I don't mind disabling for linxu32/debug for now and leave it on everywhere else until you have more cycles to hack on this. Here is a patch if you want to go this route, just r+ and I can land :)
Updated•4 years ago
|
Attachment #8860097 -
Flags: review+
Pushed by jmaher@mozilla.com: https://hg.mozilla.org/integration/mozilla-inbound/rev/5a76bb21c37d Intermittent browser/modules/test/browser/browser_UsageTelemetry_urlbar.js. temporarily disable linux32/debug. r=adw
Updated•4 years ago
|
Keywords: leave-open
Whiteboard: [stockwell needswork] → [stockwell disabled]
There was a missing "=" in the patch. Followup to fix it: https://hg.mozilla.org/integration/mozilla-inbound/rev/d8365bfecede5d0238406b38662028c35f2fdb2f
Comment 8•4 years ago
|
||
| bugherder | ||
https://hg.mozilla.org/mozilla-central/rev/5a76bb21c37d https://hg.mozilla.org/mozilla-central/rev/d8365bfecede
| Comment hidden (Intermittent Failures Robot) |
| Comment hidden (Intermittent Failures Robot) |
| Comment hidden (Intermittent Failures Robot) |
| Comment hidden (Intermittent Failures Robot) |
| Comment hidden (Intermittent Failures Robot) |
| Comment hidden (Intermittent Failures Robot) |
| Comment hidden (Intermittent Failures Robot) |
| Comment hidden (Intermittent Failures Robot) |
Updated•4 years ago
|
Whiteboard: [stockwell disabled] → [stockwell disabled][fxsearch]
Updated•4 years ago
|
Assignee: adw → nobody
Status: ASSIGNED → NEW
| Comment hidden (Intermittent Failures Robot) |
Updated•4 years ago
|
Priority: -- → P2
| Comment hidden (Intermittent Failures Robot) |
| Comment hidden (Intermittent Failures Robot) |
| Comment hidden (Intermittent Failures Robot) |
| Comment hidden (Intermittent Failures Robot) |
| Comment hidden (Intermittent Failures Robot) |
| Comment hidden (Intermittent Failures Robot) |
| Comment hidden (Intermittent Failures Robot) |
| Comment hidden (Intermittent Failures Robot) |
| Comment hidden (Intermittent Failures Robot) |
| Comment hidden (Intermittent Failures Robot) |
| Comment hidden (Intermittent Failures Robot) |
| Comment hidden (Intermittent Failures Robot) |
| Comment hidden (Intermittent Failures Robot) |
| Comment hidden (Intermittent Failures Robot) |
| Comment hidden (Intermittent Failures Robot) |
| Comment hidden (Intermittent Failures Robot) |
| Comment hidden (Intermittent Failures Robot) |
| Comment hidden (Intermittent Failures Robot) |
| Comment hidden (Intermittent Failures Robot) |
| Comment hidden (Intermittent Failures Robot) |
| Comment hidden (Intermittent Failures Robot) |
| Comment hidden (Intermittent Failures Robot) |
| Comment hidden (Intermittent Failures Robot) |
| Comment hidden (Intermittent Failures Robot) |
Updated•4 years ago
|
Flags: needinfo?(past)
Comment 42•4 years ago
|
||
This is failing because for some reason the search suggestions are coming from the wrong search engine, or are at least being annotated that way.
The label of the suggestion is supposed to be
queryfoo browser_UsageTelemetry usageTelemetrySearchSuggestions.xml Search
which is `${suggestion} ${engineName} Search` but for some reason it is getting the name of the first engine added in the test, MozSearch:
queryfoo MozSearch Search
since the test is trying to select an entry to click based on the label, and then waiting on the load that would cause, it just sits there, then times out.
https://treeherder.mozilla.org/logviewer.html#?job_id=134477711&repo=try&lineNumber=3635
However browser_UsageTelemetry usageTelemetrySearchSuggestions.xml is the currentEngine, which is why the test fails are showing the expected engine being used for the first bare "Search with ${engineName}" entry.
https://public-artifacts.taskcluster.net/Jj2x_aP3S3KA9m9NW1hDoA/0/public/test_info//mozilla-test-fail-screenshot_4zqucx.png
Is there some way for suggestions to come from an engine other than the default? Or could the suggestion code be caching the currentEngine and not updating it fast enough in debug builds?| Comment hidden (Intermittent Failures Robot) |
Comment 44•4 years ago
|
||
(In reply to Ian Moody [:Kwan] from comment #42) > This is failing because for some reason the search suggestions are coming > from the wrong search engine, or are at least being annotated that way. I suspect the suggestions are not "coming from the wrong search engine", but just not updated yet. One way to verify would be to change the "query" query at http://searchfox.org/mozilla-central/rev/a4702203522745baff21e519035b6c946b7d710d/browser/modules/test/browser/browser_UsageTelemetry_urlbar.js#380 to use a unique string instead. If my guess is correct, the increased frequency in the failures here would be caused by bug 1391293 which landed 14 days ago.
| Assignee | ||
Updated•4 years ago
|
Assignee: nobody → mak77
Status: NEW → ASSIGNED
Priority: P2 → P1
| Assignee | ||
Comment 45•4 years ago
|
||
if the test doesn't wait for the item to be updated, it's likely to do the wrong thing. Unfortunately waiting for the query to be complete is not enough.
Updated•4 years ago
|
Flags: needinfo?(past)
| Comment hidden (Intermittent Failures Robot) |
| Assignee | ||
Comment 47•4 years ago
|
||
https://treeherder.mozilla.org/#/jobs?repo=try&revision=e7e7900893af5424a120da9c2eaf402e404edc45
| Comment hidden (Intermittent Failures Robot) |
| Assignee | ||
Comment 49•4 years ago
|
||
(In reply to Florian Quèze [:florian] [:flo] from comment #44) > I suspect the suggestions are not "coming from the wrong search engine", but > just not updated yet. So, this is not the problem. I changed the test to poll for 5 seconds, and the result is constantly using MozSearch. From some first logging, looks like we properly create a SearchSuggestionController for the expected engine, and we properly set currentEngine. Still trying to understand what's up.
| Assignee | ||
Comment 50•4 years ago
|
||
I think I'm starting seeing the light at the end of the tunnel. My suspect is currently overrideSearchEngineName, a previous test indeed selects a search suggestion usageTelemetrySearchSuggestions.xml, but then selects a one-off button (MozSearch!). That overrides the name of the engine in the "url" attribute, so later when we go through the items for a suggestion from usageTelemetrySearchSuggestions.xml we find an identical one and we decide to reuse it. But this suggestion's "url" attribute in reality has been manipulated. There seems to be a bug in the code that detects whether we can completely reuse a result.
| Assignee | ||
Comment 51•4 years ago
|
||
Ah, and this is intermittent because sometimes the search in between these 2 tests may complete and remove the "reusable" entry, other times it may not.
| Assignee | ||
Comment 52•4 years ago
|
||
I declare victory https://treeherder.mozilla.org/#/jobs?repo=try&revision=1944fcb52a1f9b935a6b20b3f164375d8f8776f6
| Comment hidden (mozreview-request) |
Comment 54•4 years ago
|
||
| mozreview-review | ||
Comment on attachment 8915699 [details] Bug 1356758 - Intermittent timeouts in browser_UsageTelemetry_urlbar.js. https://reviewboard.mozilla.org/r/186910/#review192048 Make sense, thanks. ::: browser/modules/test/browser/browser_UsageTelemetry_urlbar.js:35 (Diff revision 1) > await new Promise(r => waitForFocus(r, win)); > // Write the search query in the urlbar. > win.gURLBar.focus(); > win.gURLBar.value = inputText; > + > + // This is necessary to clear oneoff buttons status. Is this really necessary now that you're nulling the selectedButton in onSearchBegin? ::: browser/modules/test/browser/browser_UsageTelemetry_urlbar.js:60 (Diff revision 1) > // The entry in the suggestion list should follow the format: > // "<search term> <engine name> Search" > const expectedSuggestionName = entryName + " " + SUGGESTION_ENGINE_NAME + " Search"; > + return BrowserTestUtils.waitForCondition(() => { > - for (let child of gURLBar.popup.richlistbox.children) { > + for (let child of gURLBar.popup.richlistbox.children) { > + dump(child.label + "\n") Did you mean to leave this here? Maybe change it to an info() if so? ::: toolkit/content/widgets/autocomplete.xml:2136 (Diff revision 1) > > > <method name="_adjustAcItem"> > <body> > <![CDATA[ > - this.setAttribute("url", this.getAttribute("ac-value")); > + let originalUrl = this.getAttribute("ac-value"); Just so I understand, it looks like these changes don't actually change any behavior, right?
Attachment #8915699 -
Flags: review?(adw) → review+
| Comment hidden (Intermittent Failures Robot) |
| Assignee | ||
Comment 56•4 years ago
|
||
| mozreview-review-reply | ||
Comment on attachment 8915699 [details] Bug 1356758 - Intermittent timeouts in browser_UsageTelemetry_urlbar.js. https://reviewboard.mozilla.org/r/186910/#review192048 > Is this really necessary now that you're nulling the selectedButton in onSearchBegin? No, it's not strictly necessary with the fix, but it doesn't hurt and may point out people to something interesting about oneoffs behavior. > Did you mean to leave this here? Maybe change it to an info() if so? ah, no I will remove that. > Just so I understand, it looks like these changes don't actually change any behavior, right? No, it's a micro-optimization to avoid getAttribute a just set attribute.
| Comment hidden (mozreview-request) |
| Comment hidden (Intermittent Failures Robot) |
Comment 59•4 years ago
|
||
Pushed by mak77@bonardo.net: https://hg.mozilla.org/integration/autoland/rev/d115a2114809 Intermittent timeouts in browser_UsageTelemetry_urlbar.js. r=adw
Comment 60•4 years ago
|
||
| bugherder | ||
https://hg.mozilla.org/mozilla-central/rev/d115a2114809
| Assignee | ||
Updated•4 years ago
|
Status: ASSIGNED → RESOLVED
Closed: 4 years ago
status-firefox56:
--- → wontfix
status-firefox57:
--- → affected
status-firefox58:
--- → fixed
Keywords: leave-open
Resolution: --- → FIXED
| Assignee | ||
Updated•4 years ago
|
Target Milestone: --- → Firefox 58
| Comment hidden (Intermittent Failures Robot) |
Comment 62•4 years ago
|
||
Please request Beta approval on this when you get a chance. And thanks for fixing this massive PITA orange!
Flags: needinfo?(mak77)
| Assignee | ||
Comment 63•4 years ago
|
||
(In reply to Ryan VanderMeulen [:RyanVM] from comment #62) > Please request Beta approval on this when you get a chance. And thanks for > fixing this massive PITA orange! This bug is unlikely to be hit by a normal user, indeed it's more likely to cause intermittent failures than real issues. On the other side, while the changes are trivial, they are not risk free. As such I'm not sure whether it's a good uplift candidate. On the other side, you could just uplift the changes to browser_UsageTelemetry_urlbar.js, those should be enough to resolve the intermittent. I'd suggest to do a Try run first, just in case. And you don't need an approval for test changes.
Flags: needinfo?(mak77) → needinfo?(ryanvm)
Comment 64•4 years ago
|
||
If just the changes to browser_UsageTelemetry_urlbar.js will suffice, then I can indeed take it from here :)
Flags: needinfo?(ryanvm)
Comment 65•4 years ago
|
||
| uplift | ||
Looks good, thanks! https://hg.mozilla.org/releases/mozilla-beta/rev/98c8f403b3acf2734a8ef0794d28c1c9fcd98ef0
Whiteboard: [stockwell disabled][fxsearch] → [stockwell fixed][fxsearch]
| Comment hidden (Intermittent Failures Robot) |
| Comment hidden (Intermittent Failures Robot) |
| Comment hidden (Intermittent Failures Robot) |
You need to log in
before you can comment on or make changes to this bug.
Description
•