Bug 206899

Summary: [Web Animations] `DeclarativeAnimation` for CSS Animation is not always destroyed when class that applies `animation-name` is removed
Product: WebKit Reporter: Devin Rousso <hi>
Component: AnimationsAssignee: Antoine Quint <graouts>
Status: RESOLVED FIXED    
Severity: Normal CC: commit-queue, dino, graouts, hi, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: WebKit Local Build   
Hardware: Unspecified   
OS: Unspecified   
See Also: https://bugs.webkit.org/show_bug.cgi?id=205434
Bug Depends on:    
Bug Blocks: 205434    
Attachments:
Description Flags
[HTML] Reduction
none
Patch none

Description Devin Rousso 2020-01-28 11:54:35 PST
Created attachment 389045 [details]
[HTML] Reduction

Attached a reduction page.

I encountered this when trying to debug 'LayoutTests/inspector/animation/lifecycle-css-animation.html', as the test would time out since Web Inspector would never get notified that the web animation had been destroyed, and only noticed it after adding logging inside WebCore.

The issue doesn't always reproduce, but it happens fairly often.
Comment 1 Radar WebKit Bug Importer 2020-01-28 11:54:52 PST
<rdar://problem/58963946>
Comment 2 Antoine Quint 2020-01-29 05:08:52 PST
Created attachment 389123 [details]
Patch
Comment 3 Devin Rousso 2020-01-29 10:10:15 PST
Comment on attachment 389123 [details]
Patch

r=me

I realize I didn't provide an easily testable reduction, but is it possible to write a test for this?  Would the `CSSAnimation` be retrievable from JavaScript somehow, so we could check that it no longer exists after this change?
Comment 4 Antoine Quint 2020-01-29 10:18:01 PST
Getting a hold from JS would prevent it from being deref'd. The other option is to make this change in the patch you're working on which introduces a test.
Comment 5 WebKit Commit Bot 2020-01-29 11:18:46 PST
The commit-queue encountered the following flaky tests while processing attachment 389123 [details]:

editing/spelling/spellcheck-async-remove-frame.html bug 158401 (authors: morrita@google.com, rniwa@webkit.org, and tony@chromium.org)
The commit-queue is continuing to process your patch.
Comment 6 WebKit Commit Bot 2020-01-29 11:19:17 PST
The commit-queue encountered the following flaky tests while processing attachment 389123 [details]:

editing/spelling/spellcheck-attribute.html bug 206178 (authors: g.czajkowski@samsung.com, mark.lam@apple.com, and rniwa@webkit.org)
imported/w3c/web-platform-tests/IndexedDB/fire-error-event-exception.html bug 201481 (authors: shvaikalesh@gmail.com and youennf@gmail.com)
The commit-queue is continuing to process your patch.
Comment 7 WebKit Commit Bot 2020-01-29 11:35:27 PST
Comment on attachment 389123 [details]
Patch

Clearing flags on attachment: 389123

Committed r255371: <https://trac.webkit.org/changeset/255371>
Comment 8 WebKit Commit Bot 2020-01-29 11:35:28 PST
All reviewed patches have been landed.  Closing bug.