Open hiway opened 6 months ago
I'm encountering the same error when running any flet code on my Linux Debian system. I tried it on Windows, and everything works fine.
DeprecationWarning: The python_jwt module is deprecated
import python_jwt as jwt
Traceback (most recent call last):
File "/home/mark/Разработка/Chesu.news/.venv/lib/python3.11/site-packages/flet_runtime/app.py", line 199, in app_async
on_app_startup(conn.page_url)
File "/home/mark/Разработка/Chesu.news/.venv/lib/python3.11/site-packages/flet_runtime/app.py", line 131, in on_app_startup
print(url_prefix, page_url)
BrokenPipeError: [Errno 32] Broken pipe
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/mark/Разработка/Chesu.news/main.py", line 49, in <module>
ft.app(target=main, assets_dir='assets')
File "/home/mark/Разработка/Chesu.news/.venv/lib/python3.11/site-packages/flet_runtime/app.py", line 70, in app
return asyncio.run(
^^^^^^^^^^^^
File "/usr/lib/python3.11/asyncio/runners.py", line 190, in run
return runner.run(main)
^^^^^^^^^^^^^^^^
File "/usr/lib/python3.11/asyncio/runners.py", line 118, in run
return self._loop.run_until_complete(task)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3.11/asyncio/base_events.py", line 653, in run_until_complete
return future.result()
^^^^^^^^^^^^^^^
File "/home/mark/Разработка/Chesu.news/.venv/lib/python3.11/site-packages/flet_runtime/app.py", line 207, in app_async
await conn.close()
File "/home/mark/Разработка/Chesu.news/.venv/lib/python3.11/site-packages/flet_runtime/flet_socket_server.py", line 191, in close
if self.__receive_loop_task:
^^^^^^^^^^^^^^^^^^^^^^^^
AttributeError: 'FletSocketServer' object has no attribute '_FletSocketServer__receive_loop_task'. Did you mean: '_FletSocketServer__receive_loop'?
^C
Duplicate of https://github.com/flet-dev/flet/issues/2781
The fix for the FletSocketServer
is present only in the latest pre-release for now:
pip install flet --pre
Oh, sorry, forgot to closely look at the first comment with the assets error.
Can you try this @hiway: https://stackoverflow.com/a/76352754
Description
Installed flet on FreeBSD 14 under virtual environment via poetry, with Python versions 3.9 and 3.11, unable to run the hello world example.
Code example to reproduce the issue:
Describe the results you received:
Describe the results you expected:
I expected the hello world example to run.
Additional information you deem important (e.g. issue happens only occasionally):
Creating the "assets" directory that Flet is expecting then makes it fail with
Flet version (
pip show flet
):Give your
requirements.txt
file (don'tpip freeze
, instead give direct packages):Operating system:
FreeBSD 14.0
Additional environment details:
Using poetry to manage virtual environment.