Crash in password UKM recorder |
|||
Issue descriptionChrome Version: 64.0.3245.0 (Developer Build) (64-bit) OS: desktop What steps will reproduce the problem? (1) Visit https://s.bootsnipp.com/iframe/d0A1k (2) Type something into all the fields, click the key icon in the omnibox and save a password (the actual values do not matter) (3) Click the icon again, the Manage passwords bubble should appear. Dismiss it. (4) Type something new into the form and click the icon. What is the expected result? Manual fallback bubble is shown. What happens instead? Crash via DCHECK. [9839:775:1019/183955.553588:FATAL:password_form_metrics_recorder.cc(301)] Check failed: CurrentBubbleOfInterest::kNone == current_bubble_ (0 vs. 1) 0 libbase.dylib 0x0000000107af19de base::debug::StackTrace::StackTrace(unsigned long) + 174 1 libbase.dylib 0x0000000107af1a9d base::debug::StackTrace::StackTrace(unsigned long) + 29 2 libbase.dylib 0x0000000107aefd4c base::debug::StackTrace::StackTrace() + 28 3 libbase.dylib 0x0000000107b88f7f logging::LogMessage::~LogMessage() + 479 4 libbase.dylib 0x0000000107b868e5 logging::LogMessage::~LogMessage() + 21 5 libchrome_dll.dylib 0x00000001186a114f password_manager::PasswordFormMetricsRecorder::RecordPasswordBubbleShown(password_manager::metrics_util::CredentialSourceType, password_manager::metrics_util::UIDisplayDisposition) + 239 6 libchrome_dll.dylib 0x00000001194c7dd0 ManagePasswordsBubbleModel::ManagePasswordsBubbleModel(base::WeakPtr<PasswordsModelDelegate>, ManagePasswordsBubbleModel::DisplayReason) + 6464 7 libchrome_dll.dylib 0x00000001194c8c5b ManagePasswordsBubbleModel::ManagePasswordsBubbleModel(base::WeakPtr<PasswordsModelDelegate>, ManagePasswordsBubbleModel::DisplayReason) + 27 8 libchrome_dll.dylib 0x0000000119a78d5f ManagePasswordsBubbleCocoa::ManagePasswordsBubbleCocoa(content::WebContents*, ManagePasswordsBubbleModel::DisplayReason, ManagePasswordsIcon*) + 127 9 libchrome_dll.dylib 0x0000000119a7900b ManagePasswordsBubbleCocoa::ManagePasswordsBubbleCocoa(content::WebContents*, ManagePasswordsBubbleModel::DisplayReason, ManagePasswordsIcon*) + 43 10 libchrome_dll.dylib 0x0000000119a799cc ManagePasswordsBubbleCocoa::Show(content::WebContents*, bool) + 604 11 libchrome_dll.dylib 0x0000000119aeb299 TabDialogsCocoa::ShowManagePasswordsBubble(bool) + 41 12 libchrome_dll.dylib 0x0000000119452ff3 chrome::ManagePasswordsForPage(Browser*) + 99 13 libchrome_dll.dylib 0x000000011944c15e chrome::BrowserCommandController::ExecuteCommandWithDisposition(int, WindowOpenDisposition) + 3854 14 libchrome_dll.dylib 0x0000000113f2a7c2 CommandUpdater::ExecuteCommandWithDisposition(int, WindowOpenDisposition) + 114 15 libchrome_dll.dylib 0x0000000113f2a740 CommandUpdater::ExecuteCommand(int) + 32 16 libchrome_dll.dylib 0x0000000119a1e0c1 ManagePasswordsDecoration::OnMousePressed(CGRect, CGPoint) + 81 17 libchrome_dll.dylib 0x00000001199fbcc6 -[AutocompleteTextFieldCell mouseDown:inRect:ofView:] + 3766 18 libchrome_dll.dylib 0x00000001199f1684 -[AutocompleteTextField mouseDown:] + 1684 19 AppKit 0x00007fffb35de24f -[NSWindow(NSEventRouting) _handleMouseDownEvent:isDelayedEvent:] + 6341 20 AppKit 0x00007fffb35daa6c -[NSWindow(NSEventRouting) _reallySendEvent:isDelayedEvent:] + 1942 21 AppKit 0x00007fffb35d9f0a -[NSWindow(NSEventRouting) sendEvent:] + 541 22 libchrome_dll.dylib 0x000000011990b9ca -[ChromeEventProcessingWindow sendEvent:] + 122 23 AppKit 0x00007fffb345e681 -[NSApplication(NSEvent) sendEvent:] + 1145 24 libchrome_dll.dylib 0x0000000113eb43c3 __34-[BrowserCrApplication sendEvent:]_block_invoke + 259 25 libbase.dylib 0x0000000107b8e17a base::mac::CallWithEHFrame(void () block_pointer) + 10 26 libchrome_dll.dylib 0x0000000113eb414f -[BrowserCrApplication sendEvent:] + 575 27 AppKit 0x00007fffb2cd9427 -[NSApplication run] + 1002 28 libbase.dylib 0x0000000107bef3e8 base::MessagePumpNSApplication::DoRun(base::MessagePump::Delegate*) + 312 29 libbase.dylib 0x0000000107bec184 base::MessagePumpCFRunLoopBase::Run(base::MessagePump::Delegate*) + 116 30 libbase.dylib 0x0000000107bde6bb base::MessageLoop::Run() + 299 31 libbase.dylib 0x0000000107cd8966 base::RunLoop::Run() + 262 32 libchrome_dll.dylib 0x0000000113ec0c78 ChromeBrowserMainParts::MainMessageLoopRun(int*) + 376 33 libcontent.dylib 0x0000000128c21fd7 content::BrowserMainLoop::RunMainMessageLoopParts() + 455 34 libcontent.dylib 0x0000000128c2cd2c content::BrowserMainRunnerImpl::Run() + 396 35 libcontent.dylib 0x0000000128c15abd content::BrowserMain(content::MainFunctionParams const&) + 397 36 libcontent.dylib 0x000000012b4b75c9 content::RunNamedProcessTypeMain(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, content::MainFunctionParams const&, content::ContentMainDelegate*) + 585 37 libcontent.dylib 0x000000012b4b8df4 content::ContentMainRunnerImpl::Run() + 1268 38 libcontent.dylib 0x000000012b4b57fd content::ContentServiceManagerMainDelegate::RunEmbedderProcess() + 61 39 libembedder.dylib 0x00000001075b2387 service_manager::Main(service_manager::MainParams const&) + 1911 40 libcontent.dylib 0x000000012b4b7339 content::ContentMain(content::ContentMainParams const&) + 89 41 libchrome_dll.dylib 0x0000000111dc2c9e ChromeMain + 270 42 Chromium 0x0000000105982de6 main + 630 43 libdyld.dylib 0x00007fffcadb7235 start + 1 44 ??? 0x0000000000000001 0x0 + 1
,
Oct 20 2017
Happens only on Mac.
,
Oct 20 2017
Problem: In ManagePasswordsBubbleModel::InteractionKeeper::ReportInteractions(), model->delegate_->GetPasswordFormMetricsRecorder() returns NULL. This is because in ManagePasswordsUIController::GetPasswordFormMetricsRecorder(), passwords_data_.form_manager() is null. This happens because after saving the credential, ManagePasswordsState::OnPasswordAutofilled is called, which clears the ManagePasswordsState data and therefore it's PasswordFormManager, which provides the PasswordFormMetricsRecorder.
,
Oct 20 2017
Possible approach: The ManagePasswordsBubbleModel::InteractionKeeper could hold on to a reference to the PasswordFormMetricsRecorder on construction.
,
Oct 23 2017
Here is a sequence of events: - Save clicked. The bubble is ordered to close and it starts the animation. The controller moved to the manage state. - The password is autofilled somewhere. ManagePasswordsUIController::OnPasswordAutofilled changes the state of the controller and orders the bubble to close the second time. - The bubble has finished the animation and is destroyed. ReportInteractions is called but the metrics recorder is gone at step 2. The bubble should be able to disappear in any state. It's like a destructor of a C++ object. It's a bug if the user clicks 'Save' or 'Never' and the controller has a different state. However, for no interaction case it can be difficult to fix. - A bubble is on the screen. - Some event changes the controller state and closes the bubble. - The bubble is destroyed after the state has changed. We could try to enforce ReportInteractions() earlier but I don't understand why a bubble needs a controller to report metrics.
,
Oct 27 2017
This landed here: https://chromium-review.googlesource.com/c/chromium/src/+/739505 Assigned the wrong bug number - off by one. |
|||
►
Sign in to add a comment |
|||
Comment 1 by battre@chromium.org
, Oct 20 2017