You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have searched the opened issues and there are no duplicates
Describe the bug
I've packed the main.py to main.exe in Windows10
flet pack main.py
when it runs it crashes with Unhandled exception in script
Traceback (most recent call last):
File "test.py", line 7, in
File "flet\app.py", line 64, in app
File "asyncio\runners.py", line 194, in run
File "asyncio\runners.py", line 118, in run
File "asyncio\base_events.py", line 687, in run_until_complete
File "flet\app.py", line 189, in app_async
File "flet_desktop_init_.py", line 39, in open_flet_view_async
File "flet_desktop_init_.py", line 87, in _locate_and_unpack_flet_view
File "flet_desktop_init.py", line 177, in __download_flet_client
File "urllib\request.py", line 240, in urlretrieve
File "urllib\request.py", line 215, in urlopen
File "urllib\request.py", line 521, in open
File "urllib\request.py", line 630, in http_response
File "urllib\request.py", line 559, in error
File "urllib\request.py", line 492, in _call_chain
File "urllib\request.py", line 639, in http_error_default
urllib.error.HTTPError: HTTP Error 404: Not Found
I thought it was my fault, but this peace of code won't start either.
Specifically, it didn’t work for me because when running the .exe, the program was trying to find and download the flet-windows.zip file in the repository at https://github.com/flet-dev/flet/releases. I find such a developer's decision to be quite controversial. Since it wasn’t available, an error occurred. And it wasn’t just me experiencing this issue, judging by the list of open issues. As soon as flet-windows.zip appeared in the repository, everything started working fine.
Additionally, you can completely uninstall Flet and reinstall it, or install it in a virtual environment (venv).
Duplicate Check
Describe the bug
I've packed the main.py to main.exe in Windows10
flet pack main.py
when it runs it crashes with Unhandled exception in script
Traceback (most recent call last):
File "test.py", line 7, in
File "flet\app.py", line 64, in app
File "asyncio\runners.py", line 194, in run
File "asyncio\runners.py", line 118, in run
File "asyncio\base_events.py", line 687, in run_until_complete
File "flet\app.py", line 189, in app_async
File "flet_desktop_init_.py", line 39, in open_flet_view_async
File "flet_desktop_init_.py", line 87, in _locate_and_unpack_flet_view
File "flet_desktop_init.py", line 177, in __download_flet_client
File "urllib\request.py", line 240, in urlretrieve
File "urllib\request.py", line 215, in urlopen
File "urllib\request.py", line 521, in open
File "urllib\request.py", line 630, in http_response
File "urllib\request.py", line 559, in error
File "urllib\request.py", line 492, in _call_chain
File "urllib\request.py", line 639, in http_error_default
urllib.error.HTTPError: HTTP Error 404: Not Found
I thought it was my fault, but this peace of code won't start either.
import flet as ft
def main(page: ft.Page):
page.title = "Hello Flet"
page.add(ft.Text("Hello, World!"))
ft.app(target=main)
It works fine in VS Code, my main.py works fine in VS Code but exe-file not work at all
Why
Code sample
Code
To reproduce
import flet
import pyinstaller
pack this code
to an exe file
flet pack main.py
try to run it
Expected behavior
No response
Screenshots / Videos
Captures
[Upload media here]
Operating System
Windows
Operating system details
windows 10
Flet version
0.25.1
Regression
No, it isn't
Suggestions
A asked chtGPT. He doesn't know )
Logs
Logs
[Paste your logs here]
Additional details
No response
The text was updated successfully, but these errors were encountered: