Bug 250354

Summary: Assertion failed: Renderer is not cleared for a detached text node
Product: WebKit Reporter: Arunsundar Kannan <arunsundar_kannan>
Component: DOMAssignee: Arunsundar Kannan <arunsundar_kannan>
Status: NEW ---    
Severity: Normal CC: cdumez, dino, graouts, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: Other   
Hardware: Unspecified   
OS: Unspecified   

Description Arunsundar Kannan 2023-01-09 21:14:14 PST
Translated Report (Full Report Below)
-------------------------------------

Process:               com.apple.WebKit.WebContent.Development [62692]
Path:                  /Users/USER/*/com.apple.WebKit.WebContent.Development
Identifier:            com.apple.WebKit.WebContent
Version:               615+ (615.1.15+)
Code Type:             ARM-64 (Native)
Parent Process:        launchd.developm [1]
Responsible:           MiniBrowser [62280]
User ID:               501

Date/Time:             2023-01-09 11:46:14.3882 -0800
OS Version:            macOS 14.0 (23A143b)
Report Version:        12
Anonymous UUID:        12A4AF09-FDD9-553C-84EB-D7B450358D58

Sleep/Wake UUID:       8DF96FCA-CFFF-42A5-96C1-2441206BB144

Time Awake Since Boot: 1900000 seconds
Time Since Wake:       11100 seconds

System Integrity Protection: disabled

Crashed Thread:        0  Dispatch queue: com.apple.main-thread

Exception Type:        EXC_BREAKPOINT (SIGTRAP)
Exception Codes:       0x0000000000000001, 0x0000000280007050

Termination Reason:    Namespace SIGNAL, Code 5 Trace/BPT trap: 5
Terminating Process:   exc handler [62692]

ASSERTION FAILED: !renderer()

Thread 0 Crashed::  Dispatch queue: com.apple.main-thread
0   JavaScriptCore                	       0x280007050 WTFCrash + 20 (Assertions.cpp:325)
1   WebCore                       	       0x2b83a9ab8 WTFCrashWithInfo(int, char const*, char const*, int) + 40 (Assertions.h:754)
2   WebCore                       	       0x2c16f563c WebCore::Node::~Node() + 2168 (Node.cpp:394)
3   WebCore                       	       0x2c117eff0 WebCore::CharacterData::~CharacterData() + 160 (CharacterData.cpp:47)
4   WebCore                       	       0x2c18ce710 WebCore::Text::~Text() + 32 (Text.cpp:57)
5   WebCore                       	       0x2c18ce740 WebCore::Text::~Text() + 32 (Text.cpp:57)
6   WebCore                       	       0x2c18ce770 WebCore::Text::~Text() + 32 (Text.cpp:57)
7   WebCore                       	       0x2c1712644 WebCore::Node::removedLastRef() + 596 (Node.cpp:2587)
8   WebCore                       	       0x2b8eb54e8 WebCore::Node::deref() const + 1048 (Node.h:822)
9   WebCore                       	       0x2b8ffe150 WTF::DefaultRefDerefTraits<WebCore::Node>::derefIfNotNull(WebCore::Node*) + 48 (RefPtr.h:42)
10  WebCore                       	       0x2b8b65a38 WTF::RefPtr<WebCore::Node, WTF::RawPtrTraits<WebCore::Node>, WTF::DefaultRefDerefTraits<WebCore::Node> >::~RefPtr() + 360 (RefPtr.h:74)
11  WebCore                       	       0x2b8b658c0 WTF::RefPtr<WebCore::Node, WTF::RawPtrTraits<WebCore::Node>, WTF::DefaultRefDerefTraits<WebCore::Node> >::~RefPtr() + 32 (RefPtr.h:74)
12  WebCore                       	       0x2bf4c804c WTF::RefPtr<WebCore::Node, WTF::RawPtrTraits<WebCore::Node>, WTF::DefaultRefDerefTraits<WebCore::Node> >::operator=(WTF::RefPtr<WebCore::Node, WTF::RawPtrTraits<WebCore::Node>, WTF::DefaultRefDerefTraits<WebCore::Node> > const&) + 332 (RefPtr.h:148)
13  WebCore                       	       0x2c11ca720 WebCore::removeDetachedChildrenInContainer(WebCore::ContainerNode&) + 1540 (ContainerNodeAlgorithms.cpp:184)
14  WebCore                       	       0x2c11c9dc0 WebCore::ContainerNode::removeDetachedChildren() + 420 (ContainerNode.cpp:333)
15  WebCore                       	       0x2c11cb2b0 WebCore::ContainerNode::~ContainerNode() + 176 (ContainerNode.cpp:373)
16  WebCore                       	       0x2c14c83f0 WebCore::Element::~Element() + 684 (Element.cpp:267)
17  WebCore                       	       0x2c18a1518 WebCore::StyledElement::~StyledElement() + 356 (StyledElement.cpp:76)
18  WebCore                       	       0x2bfbb7700 WebCore::HTMLElement::~HTMLElement() + 32 (HTMLElement.h:50)
19  WebCore                       	       0x2c21ad06c WebCore::HTMLTitleElement::~HTMLTitleElement() + 44 (HTMLTitleElement.h:30)
20  WebCore                       	       0x2c21a8f40 WebCore::HTMLTitleElement::~HTMLTitleElement() + 32 (HTMLTitleElement.h:30)
21  WebCore                       	       0x2c21a8f70 WebCore::HTMLTitleElement::~HTMLTitleElement() + 32 (HTMLTitleElement.h:30)
22  WebCore                       	       0x2c1712644 WebCore::Node::removedLastRef() + 596 (Node.cpp:2587)
23  WebCore                       	       0x2b8eb54e8 WebCore::Node::deref() const + 1048 (Node.h:822)
24  WebCore                       	       0x2baa20b50 WTF::DefaultRefDerefTraits<WebCore::Element>::derefIfNotNull(WebCore::Element*) + 48 (RefPtr.h:42)
25  WebCore                       	       0x2ba3f5408 WTF::RefPtr<WebCore::Element, WTF::RawPtrTraits<WebCore::Element>, WTF::DefaultRefDerefTraits<WebCore::Element> >::~RefPtr() + 360 (RefPtr.h:74)
26  WebCore                       	       0x2ba3f5290 WTF::RefPtr<WebCore::Element, WTF::RawPtrTraits<WebCore::Element>, WTF::DefaultRefDerefTraits<WebCore::Element> >::~RefPtr() + 32 (RefPtr.h:74)
27  WebCore                       	       0x2bfad01e0 WebCore::KeyframeEffect::~KeyframeEffect() + 228 (KeyframeEffect.h:61)
28  WebCore                       	       0x2bfa90d98 WebCore::KeyframeEffect::~KeyframeEffect() + 32 (KeyframeEffect.h:61)
29  WebCore                       	       0x2bfa90dc8 WebCore::KeyframeEffect::~KeyframeEffect() + 32 (KeyframeEffect.h:61)
30  WebCore                       	       0x2baa49554 std::__1::default_delete<WebCore::AnimationEffect>::operator()(WebCore::AnimationEffect*) const + 236 (unique_ptr.h:54)
31  WebCore                       	       0x2b851bbb0 WTF::RefCounted<WebCore::AnimationEffect, std::__1::default_delete<WebCore::AnimationEffect> >::deref() const + 336 (RefCounted.h:190)
32  WebCore                       	       0x2bcdc5a90 WTF::DefaultRefDerefTraits<WebCore::AnimationEffect>::derefIfNotNull(WebCore::AnimationEffect*) + 52 (RefPtr.h:42)
33  WebCore                       	       0x2bcdc59b0 WTF::RefPtr<WebCore::AnimationEffect, WTF::RawPtrTraits<WebCore::AnimationEffect>, WTF::DefaultRefDerefTraits<WebCore::AnimationEffect> >::~RefPtr() + 360 (RefPtr.h:74)
34  WebCore                       	       0x2bcdc5774 WTF::RefPtr<WebCore::AnimationEffect, WTF::RawPtrTraits<WebCore::AnimationEffect>, WTF::DefaultRefDerefTraits<WebCore::AnimationEffect> >::~RefPtr() + 32 (RefPtr.h:74)
35  WebCore                       	       0x2bfa75334 WebCore::WebAnimation::~WebAnimation() + 932 (WebAnimation.cpp:121)
36  WebCore                       	       0x2bf9ea210 WebCore::DeclarativeAnimation::~DeclarativeAnimation() + 248 (DeclarativeAnimation.cpp:55)
37  WebCore                       	       0x2bf937174 WebCore::CSSAnimation::~CSSAnimation() + 44 (CSSAnimation.h:42)
38  WebCore                       	       0x2bf8b9168 WebCore::CSSAnimation::~CSSAnimation() + 32 (CSSAnimation.h:42)
39  WebCore                       	       0x2bf8b9198 WebCore::CSSAnimation::~CSSAnimation() + 32 (CSSAnimation.h:42)
40  WebCore                       	       0x2b888b2e8 std::__1::default_delete<WebCore::WebAnimation>::operator()(WebCore::WebAnimation*) const + 236 (unique_ptr.h:54)
41  WebCore                       	       0x2b888b150 WTF::RefCounted<WebCore::WebAnimation, std::__1::default_delete<WebCore::WebAnimation> >::deref() const + 336 (RefCounted.h:190)
42  WebCore                       	       0x2b8bd0ab0 WTF::Ref<WebCore::WebAnimation, WTF::RawPtrTraits<WebCore::WebAnimation> >::~Ref() + 464 (Ref.h:61)
43  WebCore                       	       0x2b963eff0 WTF::Ref<WebCore::WebAnimation, WTF::RawPtrTraits<WebCore::WebAnimation> >::~Ref() + 32 (Ref.h:55)
44  WebCore                       	       0x2bfa33ba0 WTF::VectorDestructor<true, WTF::Ref<WebCore::WebAnimation, WTF::RawPtrTraits<WebCore::WebAnimation> > >::destruct(WTF::Ref<WebCore::WebAnimation, WTF::RawPtrTraits<WebCore::WebAnimation> >*, WTF::Ref<WebCore::WebAnimation, WTF::RawPtrTraits<WebCore::WebAnimation> >*) + 76 (Vector.h:69)
45  WebCore                       	       0x2bfa33a68 WTF::VectorTypeOperations<WTF::Ref<WebCore::WebAnimation, WTF::RawPtrTraits<WebCore::WebAnimation> > >::destruct(WTF::Ref<WebCore::WebAnimation, WTF::RawPtrTraits<WebCore::WebAnimation> >*, WTF::Ref<WebCore::WebAnimation, WTF::RawPtrTraits<WebCore::WebAnimation> >*) + 36 (Vector.h:252)
46  WebCore                       	       0x2bfa33a1c WTF::Vector<WTF::Ref<WebCore::WebAnimation, WTF::RawPtrTraits<WebCore::WebAnimation> >, 0ul, WTF::CrashOnOverflow, 16ul, WTF::FastMalloc>::~Vector() + 192 (Vector.h:748)
47  WebCore                       	       0x2bfa03034 WTF::Vector<WTF::Ref<WebCore::WebAnimation, WTF::RawPtrTraits<WebCore::WebAnimation> >, 0ul, WTF::CrashOnOverflow, 16ul, WTF::FastMalloc>::~Vector() + 32 (Vector.h:746)
48  WebCore                       	       0x2bfa00c94 WebCore::DocumentTimelinesController::updateAnimationsAndSendEvents(WTF::Seconds) + 7800 (DocumentTimelinesController.cpp:222)
49  WebCore                       	       0x2c1335c84 WebCore::Document::updateAnimationsAndSendEvents() + 512 (Document.cpp:8761)
50  WebCore                       	       0x2c3a3164c WebCore::Page::updateRendering()::$_24::operator()(WebCore::Document&) const + 32 (Page.cpp:1713)
51  WebCore                       	       0x2c3a315f0 WTF::Detail::CallableWrapper<WebCore::Page::updateRendering()::$_24, void, WebCore::Document&>::call(WebCore::Document&) + 40 (Function.h:53)
52  WebCore                       	       0x2c17cf234 WTF::Function<void (WebCore::Document&)>::operator()(WebCore::Document&) const + 340 (Function.h:82)
53  WebCore                       	       0x2c39a5ae0 WebCore::Page::forEachDocumentFromMainFrame(WebCore::Frame const&, WTF::Function<void (WebCore::Document&)> const&) + 628 (Page.cpp:3591)
54  WebCore                       	       0x2c396ddac WebCore::Page::forEachDocument(WTF::Function<void (WebCore::Document&)> const&) const + 40 (Page.cpp:3596)
55  WebCore                       	       0x2c3987df4 WebCore::Page::updateRendering()::$_19::operator()(WebCore::RenderingUpdateStep, WTF::Function<void (WebCore::Document&)> const&) const + 500 (Page.cpp:1692)
56  WebCore                       	       0x2c3987184 WebCore::Page::updateRendering() + 2480 (Page.cpp:1712)
57  WebKit                        	       0x1235fe858 WebKit::WebPage::updateRendering() + 36 (WebPage.cpp:4482)
58  WebKit                        	       0x11dfcaaf4 WebKit::RemoteLayerTreeDrawingArea::updateRendering() + 1640 (RemoteLayerTreeDrawingArea.mm:295)
Comment 1 Radar WebKit Bug Importer 2023-01-16 21:15:22 PST
<rdar://problem/104317270>
Comment 2 Arunsundar Kannan 2023-02-01 09:31:28 PST
Pull request: https://github.com/WebKit/WebKit/pull/9459
Comment 3 Arunsundar Kannan 2023-02-10 17:31:29 PST
Pull request: https://github.com/apple/WebKit/pull/382
Comment 4 Arunsundar Kannan 2023-02-11 10:54:34 PST
Pull request: https://github.com/apple/WebKit/pull/383