Fixed
Status Update
Comments
vi...@google.com <vi...@google.com> #3
We have shared this with our product and engineering team and will update this issue with more information as it becomes available.
xa...@google.com <xa...@google.com> #4
Moving this to Studio's side as it's a layoutlib issue, not a framework issue.
ze...@gmail.com <ze...@gmail.com> #5
While the fix takes care of the critical section for Paparazzi, have you evaluated the impact of these synchronization when used for preview in Android Studio (which impacts majority of Android developers)?
Have you considered a solution where synchronization is to be opted in and can be enabled only by paparazzi?
Have you considered a solution where synchronization is to be opted in and can be enabled only by paparazzi?
go...@jakewharton.com <go...@jakewharton.com> #6
The fix has nothing to do with Paparazzi. The code in Android Studio is broken and a similar test case as above written inside a View rendered with preview will cause the IDE to crash.
jr...@squareup.com <jr...@squareup.com> #7
What version of layoutlib has the landed CL referenced in #2?
jg...@google.com <jg...@google.com> #8
It is included in layoutlib that ships in Flamingo since Flamingo Beta 2 (2022.2.1.13), and in Giraffe since Giraffe Canary 2 (2022.3.1.2)
Description
Running Paparazzi tests on views containing
LottieAnimationView
and callingLottieAnimationView.setAnimation
will sometimes cause Paparazzi tests to fail with the following stack trace:This is because, eventually, Lottie will create a new MessageHandlerQueue.add() while MessageHandlerQueue.extractFirst() is running.
Handler
from a background thread which results in a call toThis exception can be easily reproduced with the following test case: