Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.
Sign upHeadless testing (webdriver) fails to fully render on 4th page load #18606
Comments
|
I tested this in 5f4f355 (Dec 9, 2017) and the problem still exists. |
|
I just built e5a0bb9 (Jan 9, 2018) and the problem appears to have gotten worse because it now stops rendering on the third attempt. In fact, I just discovered by accident that even if the web server is not running, I'll will get two white error pages with "Could not load the requested page: connection refused" and the third will just be an empty white page. Also, I verified that it is not just loading the same address that causes the problem. I created four test pages (each with a different message and background color). The third page loaded (and fourth and so on) shows the correct bgcolor for the page but has no other content. |
|
And @asajeffrey |
|
As another data-point, if I run (still e5a0bb9) without headless
and then do the same test above, it render only the background on the second load and on the third load servo panics. Not sure if it's useful or even related to the original issue but here is the stack:
|
|
I'm not sure if that's related or not - it might be. It's a little hard to tell from that backtrace, but I suspect that might be a crash occurring inside the GPU driver, with all the |
|
To reproduce the original problem, all I need to do is load the page once and then take three screenshots of it. By the third, I am only seeing the background colour. |
|
I don't reproduce the crashes when running without headless mode enabled. The page still keeps displaying correctly in the browser, but the screenshots only show the background colour per the original description. |
|
I can reproduce the screenshot issue locally - I'll take a look today at the WR side. |
|
Interestingly enough, if I run the servo exe with |
I *think* this is a bug in OSMesa, as the fix here makes no sense to me. But nonetheless, this change does seem to reliably fix the headless output issues as reported. Fixes servo#18606.
|
#19910 fixes this. |
Add a workaround for headless output sometimes being blank. I *think* this is a bug in OSMesa, as the fix here makes no sense to me. But nonetheless, this change does seem to reliably fix the headless output issues as reported. Fixes #18606. <!-- Reviewable:start --> --- This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/19910) <!-- Reviewable:end -->
After loading 3 pages successfully with headless/webdriver servo, the 4th page loads renders the background color of the page but no other content.
I'm running servo (built in release mode from 5a6b90b) like this:
I have the follow simple test case web page:
I then create a webdriver session:
SESSIONID=$(curl -X POST -d "{}" http://localhost:7002/session | jq -r ".value.sessionId")Then I load the test page and screenshot it like this:
The first three times I do that the screenshot looks like this:
The fourth time (and thereafter), the screenshot looks like this:
Note that if I change the background color in the html, the color in the screenshot changes so I know it's picking up the file and parsing it to get the background color.