New issue
Advanced search Search tips

Issue 727046 link

Starred by 2 users

Issue metadata

Status: Fixed
Owner:
Closed: Jun 2017
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Mac
Pri: 1
Type: Bug-Regression



Sign in to add a comment

Background color changes automagically back to old color

Reported by pop...@gmail.com, May 27 2017

Issue description

UserAgent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_5) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/58.0.3029.110 Safari/537.36

Steps to reproduce the problem:
1. Open Chrome Canary
2. Open Developer Tools
3. Change the background color to orange: document.body.style.background = "#DE640D"
4. Change the background color to white: document.body.style.background = "#FFFFFF"
5. Enter a URL (for example https://en.wikipedia.org/wiki/Barack_Obama)

What is the expected behavior?
The background color should first be orange then white and then stay white until first paint happens for the URL you entered.

What went wrong?
The background color is orange, white, changes back to orange and then first paint happens.

When you enter the URL the background color changes back to orange after a while, even though you as a user don't do anything.

Did this work before? Yes Chrome 58

Does this work in other browsers? Yes

Chrome version: 60.0.3111.0  Channel: canary
OS Version: OS X 10.12.5
Flash Version: 

This works fine in Chrome 58. I can reproduce the problem on Chrome 59 on Mac OS X and Ubuntu.
 
chrome-59.mp4
890 KB View Download
Components: Platform>DevTools
Labels: Needs-Triage-M60 Needs-Bisect

Comment 3 by ajha@chromium.org, Jun 1 2017

Cc: ajha@chromium.org
Labels: Needs-Feedback
Thanks for filing this. Somehow I was unable to repro the issue on the reported version: 60.0.3111.0 on Mac OS 10.12.4.

@reporter: Could you please review the attached screen-cast and confirm if anything being missed here.
727046.webm
4.0 MB View Download

Comment 4 by pop...@gmail.com, Jun 1 2017

Hmm that was strange, you are doing the same thing as me except that it works as expected for you. I got it on Linux too. Let me try again later today and update the issue, maybe the I did run on an earlier version.
Project Member

Comment 5 by sheriffbot@chromium.org, Jun 1 2017

Labels: -Needs-Feedback
Thank you for providing more feedback. Adding requester "ajha@chromium.org" to the cc list and removing "Needs-Feedback" label.

For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot

Comment 6 by pop...@gmail.com, Jun 1 2017

Wait a minute, it says my "Chrome version: 60.0.3111.0  Channel: canary" but if you read the issue I tried Chrome 59 (also 59 on Ubuntu). Could it be then that it has been fixed between 59 and 60? Can you try in 59 as I reported?

Comment 7 by pop...@gmail.com, Jun 1 2017

I've downloaded latest beta 59 (Version 59.0.3071.82 (Official Build) beta (64-bit)) and it happens there but not for every try.
Components: -Platform>DevTools Blink>Compositing
I can repro this on ToT Linux.
Components: -Blink>Compositing Blink>Paint
Labels: PaintTeamTriaged-20170602 BugSource-Chromium
Owner: chrishtr@chromium.org
Status: Assigned (was: Unconfirmed)
This looks very much like the fix to avoid white flashes during page navigation is picking up the wrong color in situations like this. Over to chrishtr@ to validate my theory.

The fix regressed a couple of times, which may explain why reproduction seems random.
Labels: -BugSource-Chromium BugSource-User
Cc: kkaluri@chromium.org
Labels: Needs-Feedback
Unable to reproduce this issue on Ubuntu 14.04 with chrome 61.0.3112.10, performed steps as mentioned in comment #0.

Didn't observe any change in background color while loading the url.

Attaching a screen-cast for reference.

poppap@ could you please look into it and let us know your observations.
Issue 727046.mp4
4.8 MB View Download

Comment 12 by pop...@gmail.com, Jun 5 2017

Hey! I've reported it on Chrome 59, could it be that it has been fixed then to 61? If you want to see the problem, please test on 59 :)

Do you want me to test on 61 on Ubuntu?


Cc: jmukthavaram@chromium.org
Thanks for the reply.

Able to reproduce the issue on Ubuntu 14.04 using chrome#59.0.3071.86 only on the first build after chrome installation as per the below steps.
1. Open Chrome 
2. Open Developer Tools
3. Clear Console & enter document.body.style.background = "#DE640D" & observed background color changed to orange
4. Next enter document.body.style.background = "#FFFFFF" & observed background color changed to white
5. Enter a URL https://en.wikipedia.org/wiki/Barack_Obama in the address bar of same page, observed orange screen for a while ( 1 sec)& immediately webpage displayed properly

Unable to reproduce the same issue for the next time on the same build on Linux Ubuntu ( new tab or new window)

Note: Unable to reproduce the issue on Mac & Windows 7 using 59.0.3071.86 & Canary-61.0.3122.0

We are unable to provide bisect from our end as this issue observed inconsistently .

poppap@, if possible could you please provide any other sample test/html file to reproduce the issue.

Comment 14 by pop...@gmail.com, Jun 6 2017

Hmm did you not see that pfeldman@chromium.org could reproduce on Linux (comment 8)? Check also comment 9. It's also reproducible on Mac Version 59.0.3071.86 (Official Build) (64-bit) now when 59 is stable. Try a couple of times and I hope you will see it.
It looks like the background color sent from cc to RenderWidgetHostView
as a parameter to the CompositorFrame is stale by one frame. Digging now
to find out why that is the case.
The delay by a frame is due to WebViewImpl setting the root background color
before running the lifecycle. I introduced this bug in
https://codereview.chromium.org/1526093006.


Labels: -Pri-2 ReleaseBlock-Stable M-60 Pri-1
Project Member

Comment 19 by bugdroid1@chromium.org, Jun 9 2017

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/e76d87acc9a55f551ddab222b5f8f656eee63042

commit e76d87acc9a55f551ddab222b5f8f656eee63042
Author: Chris Harrelson <chrishtr@chromium.org>
Date: Fri Jun 09 05:42:37 2017

Set the LayerTreeHost background color after updating the
DocumentLifecycle, not before.

This way any changes to the background during that update
will apply to the background passed to the LayerTreeHost.

Bug:  727046 
Change-Id: I5c2d080ffdbe52bb3d23a8bd99feb92eab1ade8a
Reviewed-on: https://chromium-review.googlesource.com/528543
Reviewed-by: Walter Korman <wkorman@chromium.org>
Commit-Queue: Chris harrelson <chrishtr@chromium.org>
Cr-Commit-Position: refs/heads/master@{#478210}
[modify] https://crrev.com/e76d87acc9a55f551ddab222b5f8f656eee63042/third_party/WebKit/Source/web/WebViewImpl.cpp
[modify] https://crrev.com/e76d87acc9a55f551ddab222b5f8f656eee63042/third_party/WebKit/Source/web/tests/WebFrameTest.cpp
[modify] https://crrev.com/e76d87acc9a55f551ddab222b5f8f656eee63042/third_party/WebKit/Source/web/tests/sim/SimCompositor.h

Labels: Merge-Request-60
Project Member

Comment 21 by sheriffbot@chromium.org, Jun 10 2017

Labels: -Merge-Request-60 Hotlist-Merge-Review Merge-Review-60
This bug requires manual review: M60 has already been promoted to the beta branch, so this requires manual review
Please contact the milestone owner if you have questions.
Owners: amineer@(Android), cmasso@(iOS), josafat@(ChromeOS), bustamante@(Desktop)

For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
Can you please confirm if this fix is verified in canary or dev?
I verified it in Canary just now.

Comment 24 by pop...@gmail.com, Jun 12 2017

I tried on Ubuntu Google Chrome "61.0.3124.4 dev" and still got the flashing, but maybe isn't there yet?
IT's in Canary but not yet Dev.
Labels: TE-Verified-M61 TE-Verified-61.0.3128.0
Verified the fix on Mac 10.12.5 using Chrome dev version #61.0.3128.0 as per the comment #0.
Attaching screen cast for reference.
Observed that background color was first orange then white and then stayed white until first paint happened for the entered URL as expected.
Hence, the fix is working as expected. 
Adding the verified labels.

Thanks...!!
727046.mp4
3.4 MB View Download
Ping - can I please merge this to M60?
Labels: -Merge-Review-60 Merge-Approved-60
Approving merge to M60. Known bug regression, and fix is well tested in canary. 
Project Member

Comment 29 by bugdroid1@chromium.org, Jun 16 2017

Labels: -merge-approved-60 merge-merged-3112
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/21058e1a3ab1a8931ceb689615302c0b8f6484e3

commit 21058e1a3ab1a8931ceb689615302c0b8f6484e3
Author: Chris Harrelson <chrishtr@chromium.org>
Date: Fri Jun 16 20:48:41 2017

Set the LayerTreeHost background color after updating the DocumentLifecycle, not before.

This way any changes to the background during that update
will apply to the background passed to the LayerTreeHost.

TBR=chrishtr@chromium.org

(cherry picked from commit e76d87acc9a55f551ddab222b5f8f656eee63042)

Bug:  727046 
Change-Id: I5c2d080ffdbe52bb3d23a8bd99feb92eab1ade8a
Reviewed-on: https://chromium-review.googlesource.com/528543
Reviewed-by: Walter Korman <wkorman@chromium.org>
Commit-Queue: Chris harrelson <chrishtr@chromium.org>
Cr-Original-Commit-Position: refs/heads/master@{#478210}
Reviewed-on: https://chromium-review.googlesource.com/538863
Reviewed-by: Chris harrelson <chrishtr@chromium.org>
Cr-Commit-Position: refs/branch-heads/3112@{#367}
Cr-Branched-From: b6460e24cf59f429d69de255538d0fc7a425ccf9-refs/heads/master@{#474897}
[modify] https://crrev.com/21058e1a3ab1a8931ceb689615302c0b8f6484e3/third_party/WebKit/Source/web/WebViewImpl.cpp
[modify] https://crrev.com/21058e1a3ab1a8931ceb689615302c0b8f6484e3/third_party/WebKit/Source/web/tests/WebFrameTest.cpp
[modify] https://crrev.com/21058e1a3ab1a8931ceb689615302c0b8f6484e3/third_party/WebKit/Source/web/tests/sim/SimCompositor.h

Status: Fixed (was: Assigned)

Sign in to add a comment