Popovers icon indicating copy to clipboard operation
Popovers copied to clipboard

After replacing the version, the cpu usage soared,

Open wisepmlin opened this issue 2 years ago • 14 comments

上传截屏2022-05-04 00.13.12.png... The source of the problem to be detected

wisepmlin avatar May 03 '22 16:05 wisepmlin

使用最新1.3.2版本

wisepmlin avatar May 03 '22 16:05 wisepmlin

Bound preference ElementPreferenceKey tried to update multiple times per frame. Bound preference ContentFrameReaderPreferenceKey tried to update multiple times per frame. Bound preference ContentFrameReaderPreferenceKey tried to update multiple times per frame. Bound preference ContentFrameReaderPreferenceKey tried to update multiple times per frame. Bound preference ContentFrameReaderPreferenceKey tried to update multiple times per frame. Bound preference ContentFrameReaderPreferenceKey tried to update multiple times per frame. Bound preference ContentFrameReaderPreferenceKey tried to update multiple times per frame. Bound preference ContentFrameReaderPreferenceKey tried to update multiple times per frame. Bound preference ContentFrameReaderPreferenceKey tried to update multiple times per frame. Bound preference ContentFrameReaderPreferenceKey tried to update multiple times per frame. Bound preference ContentFrameReaderPreferenceKey tried to update multiple times per frame. Bound preference ContentFrameReaderPreferenceKey tried to update multiple times per frame. Bound preference ContentFrameReaderPreferenceKey tried to update multiple times per frame.

wisepmlin avatar May 03 '22 16:05 wisepmlin

I can't open the png, could you upload it again?

aheze avatar May 03 '22 18:05 aheze

截屏2022-05-04 02 06 26

wisepmlin avatar May 03 '22 18:05 wisepmlin

After closing the popover, the window still occupies the cpu

wisepmlin avatar May 03 '22 18:05 wisepmlin

My interaction is in the page, some of them occupy more than 90% of the CPU, and the page is seriously stuck.

wisepmlin avatar May 03 '22 18:05 wisepmlin

Huh. Is your app running on iOS? Try making a minimal reproducible example so I can reproduce

aheze avatar May 04 '22 03:05 aheze

https://user-images.githubusercontent.com/74945717/167072910-ce0e72df-f9cb-4c8a-8211-9852d9a89a8a.MP4

wisepmlin avatar May 06 '22 05:05 wisepmlin

截屏2022-05-06 13 31 25

wisepmlin avatar May 06 '22 05:05 wisepmlin

截屏2022-05-06 13 30 57

wisepmlin avatar May 06 '22 05:05 wisepmlin

截屏2022-05-06 13 30 36

wisepmlin avatar May 06 '22 05:05 wisepmlin

That looks really weird. So it was working fine back in v1.3.1, but broke in v1.3.2? I didn't change the code much. The problem is probably here though: .onValueChange(of: transaction?.animation) { _, _ in.

I'll take a look next week (got a bunch of exams right now...) but feel free to investigate or make a PR yourself if you want.

aheze avatar May 06 '22 13:05 aheze

Development is tight, I first return to the system components, there is time to study the reasons

wisepmlin avatar May 08 '22 13:05 wisepmlin

The height of the encapsulated component with uikit's UItextKit creates a refresh conflict in LazyVStask's container, causing rendering to bounce

wisepmlin avatar Jun 07 '22 05:06 wisepmlin