New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 847211 link

Starred by 1 user

Issue metadata

Status: Fixed
Owner:
Last visit > 30 days ago
Closed: Jun 2018
Components:
EstimatedDays: ----
NextAction: ----
OS: Linux
Pri: 3
Type: Bug



Sign in to add a comment

DCHECK crash (destroying pending blink promise) when navigating videos on YouTube for TVs.

Project Member Reported by kolc...@vewd.com, May 28 2018

Issue description

Chrome Version: 69.0.3444.0
OS: Linux

What steps will reproduce the problem?
(1) ./content_shell http://www.youtube.com/tv
(2) Play any video.
(3) As soon as the related videos show up at the bottom, click on one of them.
(4) If it hasn't crashed, go back to step 3.

What is the expected result?
The video changes and new one gets played.

What happens instead?
Occasional DCHECK crash:

[1:1:0523/170600.530654:4073660532362:FATAL:script_promise_resolver.h(57)] Check failed: state_ == kDetached || !is_promise_called_ || !GetScriptState()->ContextIsValid() || !GetExecutionContext() || GetExecutionContext()->IsContextDestroyed(). 
#0 0x7f587170f76c base::debug::StackTrace::StackTrace()
#1 0x7f587172f3ae logging::LogMessage::~LogMessage()
#2 0x7f587277b869 blink::ScriptPromiseResolver::~ScriptPromiseResolver()
#3 0x7f58710ab61d blink::NormalPage::Sweep()
#4 0x7f58710a7dbe blink::BaseArena::SweepUnsweptPage()
#5 0x7f58710a3df5 blink::BaseArena::CompleteSweep()
#6 0x7f58710b74e3 blink::ThreadState::EagerSweep()
#7 0x7f58710b70a3 blink::ThreadState::PreSweep()
#8 0x7f58710b3b12 blink::ThreadState::CollectGarbage()
#9 0x7f58710b5766 blink::ThreadState::PerformIdleGC()

 

 

Comment 1 by kolc...@vewd.com, May 28 2018

This is a different issue than https://bugs.chromium.org/p/chromium/issues/detail?id=831118 despite the same DCHECK being hit.

I have a candidate fix that I will cl upload soon.

Comment 2 by kolc...@vewd.com, Jun 13 2018

Discussion and fix candidate in https://chromium-review.googlesource.com/c/chromium/src/+/1075308
Project Member

Comment 3 by bugdroid1@chromium.org, Jun 16 2018

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

commit d6827fb7e8cabfcdc8b386f5a6f244f4c2e5743e
Author: Krzysztof Olczyk <kolczyk@vewd.com>
Date: Sat Jun 16 05:15:05 2018

Resolve MediaCapabilities::decodingInfo promise even if mojo connection dies.

Promise for MediaCapabilities::decodingInfo() is resolved by
blink::WebMediaCapabilitiesQueryCallbacks which is passed to
WebMediaCapabilitiesClientImpl::DecodingInfo in //media/blink,
which, in some cases, means to resolve it in the callback
of an async mojo call. However, if the connections is lost meanwhile,
neither OnSuccess nor OnError is called and, in the result,
the promise resolver remains in pending state.

This patch makes sure the OnError is called when mojo connection
gets dropped.

Bug:  847211 
Change-Id: I018792c56a3d3074b042e4318d9a8b85b3c16360
Reviewed-on: https://chromium-review.googlesource.com/1075308
Reviewed-by: Kentaro Hara <haraken@chromium.org>
Reviewed-by: Chrome Cunningham <chcunningham@chromium.org>
Reviewed-by: Mounir Lamouri <mlamouri@chromium.org>
Commit-Queue: Chrome Cunningham <chcunningham@chromium.org>
Cr-Commit-Position: refs/heads/master@{#567874}
[modify] https://crrev.com/d6827fb7e8cabfcdc8b386f5a6f244f4c2e5743e/media/blink/BUILD.gn
[modify] https://crrev.com/d6827fb7e8cabfcdc8b386f5a6f244f4c2e5743e/media/blink/webmediacapabilitiesclient_impl.cc
[modify] https://crrev.com/d6827fb7e8cabfcdc8b386f5a6f244f4c2e5743e/media/blink/webmediacapabilitiesclient_impl.h
[add] https://crrev.com/d6827fb7e8cabfcdc8b386f5a6f244f4c2e5743e/media/blink/webmediacapabilitiesclient_impl_unittest.cc

Comment 4 by kolc...@vewd.com, Jun 18 2018

Status: Fixed (was: Assigned)
Project Member

Comment 5 by bugdroid1@chromium.org, Jun 19 2018

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

commit 6e14efc13e8c4687b8fc6984c542bed0969a6a04
Author: Krzysztof Olczyk <kolczyk@vewd.com>
Date: Tue Jun 19 19:42:19 2018

Move content::ScopedWebCallbacks to blink platform.

The content::ScopedWebCallbacks class is a helper for blink::WebCallbacks
and does not do anything strictly related to //content.
Moving it to //third_party/blink/public/platform makes it possible
to use it in all blink platform consumer, also the ones outside of //content,
such as //media/blink.
One example is //media/blink/webmediacapabilitiesclient_impl.cc which before
had to use specialized local copy of it.

This also adds two modifications to ScopedWebCallbacks:
* Make make_scoped_web_callbacks take a unique_ptr to WebCallbacks,
  instead of raw pointer that gets silently WrapUnique'ed inside,
  to make ownership passing more explicit,
* Modernize it to operate on OnceCallback, instead of Callback,
* Use default move constructor and move assignment.

Bug:  847211 
Change-Id: I3d9b8a660dbfd66cf8721331777f36ea42c04bc8
Reviewed-on: https://chromium-review.googlesource.com/1104356
Commit-Queue: Chrome Cunningham <chcunningham@chromium.org>
Reviewed-by: Chrome Cunningham <chcunningham@chromium.org>
Reviewed-by: Kentaro Hara <haraken@chromium.org>
Cr-Commit-Position: refs/heads/master@{#568572}
[modify] https://crrev.com/6e14efc13e8c4687b8fc6984c542bed0969a6a04/content/child/BUILD.gn
[modify] https://crrev.com/6e14efc13e8c4687b8fc6984c542bed0969a6a04/content/renderer/image_capture/image_capture_frame_grabber.cc
[modify] https://crrev.com/6e14efc13e8c4687b8fc6984c542bed0969a6a04/content/renderer/image_capture/image_capture_frame_grabber.h
[modify] https://crrev.com/6e14efc13e8c4687b8fc6984c542bed0969a6a04/content/renderer/media_recorder/media_recorder_handler.cc
[modify] https://crrev.com/6e14efc13e8c4687b8fc6984c542bed0969a6a04/media/blink/webmediacapabilitiesclient_impl.cc
[modify] https://crrev.com/6e14efc13e8c4687b8fc6984c542bed0969a6a04/third_party/blink/public/BUILD.gn
[rename] https://crrev.com/6e14efc13e8c4687b8fc6984c542bed0969a6a04/third_party/blink/public/platform/scoped_web_callbacks.h
[modify] https://crrev.com/6e14efc13e8c4687b8fc6984c542bed0969a6a04/third_party/blink/public/platform/web_image_capture_frame_grabber.h
[modify] https://crrev.com/6e14efc13e8c4687b8fc6984c542bed0969a6a04/third_party/blink/renderer/modules/imagecapture/image_capture.cc

Sign in to add a comment