brave / brave-browser

Brave browser for Android, iOS, Linux, macOS, Windows.
https://brave.com
Mozilla Public License 2.0
17.63k stars 2.3k forks source link

Brave crashed when attempted to close Brave talk tab #41152

Open MadhaviSeelam opened 2 weeks ago

MadhaviSeelam commented 2 weeks ago

Description

Brave crashed upon closing Brave talk tab after All hands meeting concluded on 1.70.117 in Win 11 x64. Unable to reproduce the issue. I had opened account.brave.com and got login link to my brave email address in two tabs prior to that. However, I have not clicked the link to land on subscription page.

Steps to reproduce

  1. Install 1.70.117
  2. launch Brave
  3. opened account.brave.com and entered email address to get login link
  4. opened mail.google.com and logged into gmail account
  5. verified I got login link but not clicked
  6. opened and closed Leo side panel couple of times
  7. logged into All hands meeting link
  8. disconnected the call and closed the Brave talk tab at the end

Actual result

Brave crashed

![image](https://github.com/user-attachments/assets/6dcb4c96-a75c-4efb-bb47-dd7bc5a7f793)

Crash from Thursday, September 19, 2024 at 12:03:01 PM
Status: Uploaded
Uploaded Crash Report ID:   d9c50400-162b-a10c-0000-000000000000
Upload Time:    Thursday, September 19, 2024 at 12:05:46 PM

[ 00 ] ai_chat::ConversationDriver::IsContentAssociationPossible() ( conversation_driver.cc:1200 )
[ 01 ] ai_chat::ConversationDriver::MaybeSeedOrClearSuggestions() ( conversation_driver.cc:506 )
[ 02 ] ai_chat::ConversationDriver::OnConversationActiveChanged(bool) ( conversation_driver.cc:305 )
[ 03 ] ai_chat::AIChatUIPageHandler::OnVisibilityChanged(content::Visibility) ( ai_chat_ui_page_handler.cc:469 )
[ 04 ] content::WebContentsImpl::WebContentsObserverList::NotifyObservers((content::Visibility),content::Visibility &) ( web_contents_impl.h:1685 )
[ 05 ] content::WebContentsImpl::SetVisibilityAndNotifyObservers(content::Visibility) ( web_contents_impl.cc:6155 )
[ 06 ] content::WebContentsImpl::UpdateVisibilityAndNotifyPageAndView(content::Visibility,bool) ( web_contents_impl.cc:4379 )
[ 07 ] content::WebContentsImpl::UpdateWebContentsVisibility(content::Visibility) ( web_contents_impl.cc:10534 )
[ 08 ] aura::Window::SetOcclusionInfo(aura::Window::OcclusionState,SkRegion const &) ( window.cc:1104 )
[ 09 ] std::__Cr::vector<base::raw_ptr<aura::Window,1>,std::__Cr::allocator<base::raw_ptr<aura::Window,1> > >::empty() ( vector:640 )
[ 10 ] aura::DefaultWindowOcclusionChangeBuilder::~DefaultWindowOcclusionChangeBuilder() ( window_occlusion_change_builder.cc:30 )
[ 11 ] SkRegion::freeRuns() ( SkRegion.cpp:145 )
[ 12 ] SkRegion::~SkRegion() ( SkRegion.cpp:139 )
[ 13 ] aura::WindowOcclusionTracker::MaybeComputeOcclusion() ( window_occlusion_tracker.cc:397 )
[ 14 ] aura::WindowOcclusionTracker::Unpause() ( window_occlusion_tracker.cc:814 )
[ 15 ] aura::WindowOcclusionTracker::ScopedPause::~ScopedPause() ( window_occlusion_tracker.cc:200 )
[ 16 ] aura::Window::SetVisibleInternal(bool) ( window.cc:1090 )
[ 17 ] gfx::Transform::operator!=(gfx::Transform const &) ( transform.h:141 )
[ 18 ] views::NativeViewHostAura::ShowWidget(int,int,int,int,int,int) ( native_view_host_aura.cc:245 )
[ 19 ] views::NativeViewHost::Layout(base::NonCopyablePassKey<views::View>) ( native_view_host.cc:154 )
[ 20 ] views::View::LayoutImmediately() ( view.cc:3539 )
[ 21 ] views::View::Layout(base::NonCopyablePassKey<views::View>) ( view.cc:934 )
[ 22 ] views::View::LayoutImmediately() ( view.cc:3538 )
[ 23 ] views::View::DeprecatedLayoutImmediately() ( view.cc:910 )
[ 24 ] views::LayoutManagerBase::ApplyLayout(views::ProposedLayout const &) ( layout_manager_base.cc:227 )
[ 25 ] views::LayoutManagerBase::LayoutImpl() ( layout_manager_base.cc:194 )
[ 26 ] views::LayoutManagerBase::Layout(views::View *) ( layout_manager_base.cc:112 )
[ 27 ] views::View::Layout(base::NonCopyablePassKey<views::View>) ( view.cc:918 )
[ 28 ] views::View::LayoutImmediately() ( view.cc:3538 )
[ 29 ] views::View::SetBoundsRect(gfx::Rect const &) ( view.cc:415 )
[ 30 ] BraveSidePanel::Layout(base::NonCopyablePassKey<views::View>) ( brave_side_panel.cc:129 )
[ 31 ] views::View::LayoutImmediately() ( view.cc:3539 )
[ 32 ] views::View::SetBoundsRect(gfx::Rect const &) ( view.cc:415 )
[ 33 ] std::__Cr::__tree<std::__Cr::__value_type<const void *,ui::PropertyHandler::Value>,std::__Cr::__map_value_compare<const void *,std::__Cr::__value_type<const void *,ui::PropertyHandler::Value>,std::__Cr::less<const void *>,1>,std::__Cr::allocator<std::__Cr::__value_type<const void *,ui::PropertyHandler::Value> > >::find(void const * const &) ( __tree:2092 )
[ 34 ] SidebarContainerView::Layout(base::NonCopyablePassKey<views::View>) ( sidebar_container_view.cc:316 )
[ 35 ] views::View::LayoutImmediately() ( view.cc:3539 )
[ 36 ] views::View::SetBoundsRect(gfx::Rect const &) ( view.cc:464 )
[ 37 ] BraveBrowserViewLayout::LayoutSideBar(gfx::Rect &) ( brave_browser_view_layout.cc:234 )
[ 38 ] BraveBrowserViewLayout::LayoutSidePanelView(views::View *,gfx::Rect &) ( brave_browser_view_layout.cc:132 )
[ 39 ] BrowserViewLayout::LayoutContentsContainerView(int,int) ( browser_view_layout.cc:772 )
[ 40 ] BraveBrowserViewLayout::LayoutContentsContainerView(int,int) ( brave_browser_view_layout.cc:184 )
[ 41 ] BrowserViewLayout::Layout(views::View *) ( browser_view_layout.cc:488 )
[ 42 ] BraveBrowserViewLayout::Layout(views::View *) ( brave_browser_view_layout.cc:66 )
[ 43 ] views::View::Layout(base::NonCopyablePassKey<views::View>) ( view.cc:928 )
[ 44 ] views::View::LayoutSuperclass(BrowserView *) ( view.h:1901 )
[ 45 ] BrowserView::Layout(base::NonCopyablePassKey<views::View>) ( browser_view.cc:4428 )
[ 46 ] views::View::LayoutSuperclass(BraveBrowserView *) ( view.h:1901 )
[ 47 ] BraveBrowserView::Layout(base::NonCopyablePassKey<views::View>) ( brave_browser_view.cc:1268 )
[ 48 ] views::View::LayoutImmediately() ( view.cc:3539 )
[ 49 ] views::View::SetBoundsRect(gfx::Rect const &) ( view.cc:415 )
[ 50 ] views::NonClientFrameView::Layout(base::NonCopyablePassKey<views::View>) ( non_client_view.cc:134 )
[ 51 ] views::View::LayoutSuperclass(BrowserFrameViewWin *) ( view.h:1901 )
[ 52 ] BrowserFrameViewWin::Layout(base::NonCopyablePassKey<views::View>) ( browser_frame_view_win.cc:484 )
[ 53 ] views::View::LayoutImmediately() ( view.cc:3539 )
[ 54 ] views::View::SetBoundsRect(gfx::Rect const &) ( view.cc:415 )
[ 55 ] views::NonClientView::Layout(base::NonCopyablePassKey<views::View>) ( non_client_view.cc:292 )
[ 56 ] views::View::LayoutImmediately() ( view.cc:3539 )
[ 57 ] views::View::DeprecatedLayoutImmediately() ( view.cc:910 )
[ 58 ] views::LayoutManagerBase::ApplyLayout(views::ProposedLayout const &) ( layout_manager_base.cc:227 )
[ 59 ] views::LayoutManagerBase::LayoutImpl() ( layout_manager_base.cc:194 )
[ 60 ] views::LayoutManagerBase::Layout(views::View *) ( layout_manager_base.cc:112 )
[ 61 ] views::View::Layout(base::NonCopyablePassKey<views::View>) ( view.cc:918 )
[ 62 ] views::View::LayoutImmediately() ( view.cc:3538 )
[ 63 ] views::Widget::LayoutRootViewIfNecessary() ( widget.cc:2068 )
[ 64 ] ui::Layer::SendDamagedRects() ( layer.cc:1355 )
[ 65 ] ui::Compositor::SendDamagedRectsRecursive(ui::Layer *) ( compositor.cc:776 )
[ 66 ] std::__Cr::vector<base::raw_ptr<ui::Layer,1>,std::__Cr::allocator<base::raw_ptr<ui::Layer,1> > >::size() ( vector:634 )
[ 67 ] ui::Compositor::SendDamagedRectsRecursive(ui::Layer *) ( compositor.cc:778 )
[ 68 ] cc::LayerTreeHost::RequestMainFrameUpdate(bool) ( layer_tree_host.cc:385 )
[ 69 ] cc::SingleThreadProxy::DoBeginMainFrame(viz::BeginFrameArgs const &) ( single_thread_proxy.cc:1165 )
[ 70 ] cc::SingleThreadProxy::BeginMainFrame(viz::BeginFrameArgs const &) ( single_thread_proxy.cc:1113 )
[ 71 ] base::OnceCallback<void ()>::Run() ( callback.h:156 )
[ 72 ] base::TaskAnnotator::RunTaskImpl(base::PendingTask &) ( task_annotator.cc:203 )
[ 73 ] base::TaskAnnotator::RunTask(perfetto::StaticString,base::PendingTask &,base::sequence_manager::internal::ThreadControllerWithMessagePumpImpl::DoWorkImpl::<lambda_4> &&) ( task_annotator.h:90 )
[ 74 ] base::sequence_manager::internal::ThreadControllerWithMessagePumpImpl::DoWorkImpl(base::LazyNow *) ( thread_controller_with_message_pump_impl.cc:484 )
[ 75 ] base::sequence_manager::internal::ThreadControllerWithMessagePumpImpl::DoWork() ( thread_controller_with_message_pump_impl.cc:346 )
[ 76 ] base::MessagePumpForUI::DoRunLoop() ( message_pump_win.cc:259 )
[ 77 ] base::MessagePumpWin::Run(base::MessagePump::Delegate *) ( message_pump_win.cc:84 )
[ 78 ] base::sequence_manager::internal::ThreadControllerWithMessagePumpImpl::Run(bool,base::TimeDelta) ( thread_controller_with_message_pump_impl.cc:657 )
[ 79 ] base::RunLoop::Run(base::Location const &) ( run_loop.cc:136 )
[ 80 ] content::BrowserMainLoop::RunMainMessageLoop() ( browser_main_loop.cc:1101 )
[ 81 ] content::BrowserMainRunnerImpl::Run() ( browser_main_runner_impl.cc:157 )
[ 82 ] content::BrowserMain(content::MainFunctionParams) ( browser_main.cc:34 )
[ 83 ] RunBrowserProcessMain(content::MainFunctionParams,content::ContentMainDelegate *) ( content_main_runner_impl.cc:732 )
[ 84 ] content::ContentMainRunnerImpl::RunBrowser(content::MainFunctionParams,bool) ( content_main_runner_impl.cc:1306 )
[ 85 ] content::ContentMainRunnerImpl::Run() ( content_main_runner_impl.cc:1158 )
[ 86 ] RunContentProcess(content::ContentMainParams,content::ContentMainRunner *) ( content_main.cc:331 )
[ 87 ] content::ContentMain(content::ContentMainParams) ( content_main.cc:344 )
[ 88 ] ChromeMain(HINSTANCE__ *,sandbox::SandboxInterfaceInfo *,__int64,__int64,__int64) ( chrome_main.cc:232 )
[ 89 ] MainDllLoader::Launch(HINSTANCE__ *,base::TimeTicks) ( main_dll_loader_win.cc:201 )
[ 90 ] wWinMain(HINSTANCE__ *,HINSTANCE__ *,wchar_t *,int) ( chrome_exe_main_win.cc:351 )
[ 91 ] invoke_main() ( exe_common.inl:118 )
[ 92 ] __scrt_common_main_seh() ( exe_common.inl:288 )
[ 93 ] BaseThreadInitThunk
[ 94 ] RtlUserThreadStart
[ 95 ] UnhandledExceptionFilter

Expected result

No crash should happen

Reproduces how often

Easily reproduced

Brave version (brave://version info)

Brave 1.70.117 Chromium: 129.0.6668.59 (Official Build) (64-bit)
Revision 5d4da8332eb061f79bb47ec5b0bf595600fdcd55
OS Windows 11 Version 23H2 (Build 22631.4169)

Channel information

Reproducibility

Miscellaneous information

@rebron cc: @qa

darkdh commented 2 weeks ago

cc @petemill

https://github.com/brave/brave-core/blob/5d4da8332eb061f79bb47ec5b0bf595600fdcd55/components/ai_chat/core/browser/conversation_driver.cc#L1200C20-L1200C30

petemill commented 2 weeks ago

Weird that it can crash there when the tab helper is still alive - it should be able to access the url. OnConversationActiveChanged should probably only do work if the param is true. It's different in the refactor.

darkdh commented 2 weeks ago

same callback as this in chromium 129 PR cc @mkarolin