New issue
Advanced search Search tips

Issue 692751 link

Starred by 1 user

Issue metadata

Status: Archived
Owner:
Closed: Mar 2017
Cc:
EstimatedDays: ----
NextAction: ----
OS: Chrome
Pri: 2
Type: Bug



Sign in to add a comment

CromeOS OOBE: "Uncaught ReferenceError: login is not defined", source: (1)

Project Member Reported by alemate@chromium.org, Feb 15 2017

Issue description

Sometimes during ChromeOS booting into OOBE I get a message like:

ERROR:CONSOLE(1)] "Uncaught ReferenceError: login is not defined", source:  (1)

This looks like a race. We need to figure out what is the source of this message.

I tried naive method of displaying all CallJS calls (see patch attached), but this seems to affect the timing and error disappeared.

Probably we should modify WebUI::GetJavascriptCall() to produce JS code that catches exceptions and displays a more friendly error message.

You may find this command-line useful to debug the issue:

time ninja -C out/Release/ -j3000 chrome chrome_sandbox  && (UDD=$HOME/cros-test-user-data-dir-tmp ; rm -rf $HOME/cros-test-user-data-dir-tmp ; mkdir -p $HOME/cros-test-user-data-dir-tmp ; ./out/Release/chrome --login-manager --login-profile=user --user-data-dir=$UDD  --disable-setuid-sandbox --no-sandbox  --remote-debugging-port=9999  )

 
debug-calljs.patch
3.2 KB Download
Project Member

Comment 1 by bugdroid1@chromium.org, Mar 2 2017

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

commit 3dc4062eddbbe88c416a21bd92986645ddb43b50
Author: wzang <wzang@chromium.org>
Date: Thu Mar 02 00:11:47 2017

Fix of "login is not defined" error in OOBE

The cause of the error is that by the time OnTouchViewToggled in SigninScreenHandler is called, oobe.js may not have completed intialization yet, so we should wait until the JS message is received.

BUG= 692751 
CQ_INCLUDE_TRYBOTS=master.tryserver.chromium.linux:closure_compilation

Review-Url: https://codereview.chromium.org/2697063004
Cr-Commit-Position: refs/heads/master@{#454111}

[modify] https://crrev.com/3dc4062eddbbe88c416a21bd92986645ddb43b50/chrome/browser/ui/webui/chromeos/login/base_screen_handler.cc
[modify] https://crrev.com/3dc4062eddbbe88c416a21bd92986645ddb43b50/chrome/browser/ui/webui/chromeos/login/base_screen_handler.h
[modify] https://crrev.com/3dc4062eddbbe88c416a21bd92986645ddb43b50/chrome/browser/ui/webui/chromeos/login/core_oobe_handler.cc
[modify] https://crrev.com/3dc4062eddbbe88c416a21bd92986645ddb43b50/chrome/browser/ui/webui/chromeos/login/core_oobe_handler.h
[modify] https://crrev.com/3dc4062eddbbe88c416a21bd92986645ddb43b50/chrome/browser/ui/webui/chromeos/login/oobe_ui.cc
[modify] https://crrev.com/3dc4062eddbbe88c416a21bd92986645ddb43b50/chrome/browser/ui/webui/chromeos/login/oobe_ui.h
[modify] https://crrev.com/3dc4062eddbbe88c416a21bd92986645ddb43b50/chrome/browser/ui/webui/chromeos/login/signin_screen_handler.cc
[modify] https://crrev.com/3dc4062eddbbe88c416a21bd92986645ddb43b50/chrome/browser/ui/webui/chromeos/login/signin_screen_handler.h

Comment 2 by wzang@chromium.org, Mar 2 2017

Status: Fixed (was: Assigned)

Comment 3 by st...@chromium.org, Mar 3 2017

Cc: r...@chromium.org

Comment 4 by st...@chromium.org, Mar 3 2017

Cc: -st...@chromium.org

Comment 5 by dchan@google.com, May 30 2017

Labels: VerifyIn-60

Comment 6 by dchan@chromium.org, Aug 1 2017

Labels: VerifyIn-61

Comment 7 by dchan@chromium.org, Jan 22 2018

Status: Archived (was: Fixed)

Sign in to add a comment