[Question] Destroying the window takes EXTREAMLY long time! #5601
-
QuestionAll these three expressions are EXTREMELY SLOW! Btw, English is not my first language 😄. Code sampleimport flet as ft
def main(page: ft.Page):
page.title = "性能测试"
def close_app(e):
page.window.destroy()
page.add(ft.FilledButton("立即关闭", on_click=close_app))
page.update()
ft.app(target=main)Environment Information------------------------------------------------------
|
Beta Was this translation helpful? Give feedback.
Replies: 2 comments
-
|
Major Update: I have captured a debug log that pinpoints the exact location of the delay! I enabled debug logging (logging.basicConfig(level=logging.DEBUG)) and captured the following output when clicking the close button. The Key Finding: Here is the relevant part of the log: Details
This confirms that the issue is not in sending the command, but in the final handshake or process termination step between the Python script and the fletd process on my specific Windows 11 environment. |
Beta Was this translation helpful? Give feedback.
-
|
okay, using page.window.close() instead of page.window.destroy() solved the problem 😄. |
Beta Was this translation helpful? Give feedback.
okay, using page.window.close() instead of page.window.destroy() solved the problem 😄.