New issue
Advanced search Search tips

Issue 821273 link

Starred by 1 user

Issue metadata

Status: Available
Owner: ----
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Windows
Pri: 3
Type: Bug



Sign in to add a comment

Missing GN dependency in independent_otr_profile_manager.cc

Reported by fatalerr@yandex-team.ru, Mar 13 2018

Issue description

UserAgent: Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/64.0.3282.99 YaBrowser/18.3.1.148 (beta) Yowser/2.5 Safari/537.36

Steps to reproduce the problem:
File chrome/browser/media/router/presentation/independent_otr_profile_manager.cc includes some chrome/browser/* & chrome/browser/ui/* headers, but it's target (//chrome/browser/media/router) doesn't depend on //chrome/browser and //chrome/browser/ui.

What is the expected behavior?

What went wrong?
This leads to flaky Chromium builds.

For example, the said file includes chrome/browser/ui/browser.h, which includes components/translate/content/browser/content_translate_driver.h, which includes components/translate/content/common/translate.mojom.h which is a generated file - if it's not generated at the time chrome/browser/media/router/presentation/independent_otr_profile_manager.cc is compiled, the whole build fails.

Did this work before? No 

Chrome version: 64.0.3282.99  Channel: n/a
OS Version: 6.1 (Windows 7, Windows Server 2008 R2)
Flash Version: Shockwave Flash 28.0 r0
 
Labels: Needs-Triage-M64
Components: Blink>Media
Labels: TE-NeedsTriageHelp
Components: -Blink>Media Internals>Cast

Comment 5 by mfo...@chromium.org, Jun 25 2018

Labels: -Pri-2 Pri-3
Owner: mfo...@chromium.org
Status: Assigned (was: Unconfirmed)

Comment 6 by mfo...@chromium.org, Jun 26 2018

Status: Started (was: Assigned)

Comment 7 by mfo...@chromium.org, Jun 26 2018

Cc: btolsch@chromium.org
Owner: ----
Status: Available (was: Started)
I took a look at this.  There is a dependency cycle that is going to be difficult to break:

ERROR Dependency cycle:
  //chrome/browser/ui:ui ->
  //chrome/browser/apps:apps ->
  //chrome/browser/extensions:extensions ->
  //chrome/browser/media/router:router ->
  //chrome/browser/ui:ui

The IOPM needs browser.h, and c/b/extensions needs c/b/media/router for various reasons.

We'll probably have to refactor IOPM to implement a factory/interface and inject it into c/b/media/router to break this cycle.  This is not something I have bandwidth for right now, unfortunately.

btolsch@ wrote the original implementation and might have other ideas I'm missing.

Sign in to add a comment