Hacktoberfest 2026: những issue maintainer đã đánh dấu cho tháng Mười, đang mở và phù hợp người mới. Xem issue Hacktoberfest

Fail to debug run_example

Đang mở
#117 0 bình luận 0 reaction 0 người được giao Xem trên GitHub

Chưa có ai nhận issue này.

Đánh giá

Độ khó
4/5
Thời gian dự kiến
3-5 ngày
Mức phù hợp với người mới
35/100
Loại issue
Lỗi
Độ rõ ràng
Khá rõ ràng
Mức độ hoạt động
Đình trệ
Công nghệ
dart, flutter, python, vscode

Hướng nghiên cứu

Tái hiện luồng debug của VSCode cho run_example sau khi build app.zip, bắt đầu với lib\main.dart và flet\app\main.py đã được đóng gói hiển thị trong log. Kiểm tra lý do runtime debug không thể tải lru._lru dù archive được dùng chung với chế độ release. Hoàn tất khi quá trình debug run_example kết thúc và hiển thị PASS mà không có ModuleNotFoundError.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

Hi I tried to run run_example using VSCode, and I package app.zip and build run_example.exe successfully. But when I tried to Debug it, there is a python file name shown in panel instead of PASS. I checked the OUTPUT and DEBUG CONSOLE, I find an error "no module named lru".
image
Detailed information are as followed:

Launching lib\main.dart on Windows in debug mode...
√ Built build\windows\x64\runner\Debug\run_example.exe
Connecting to VM Service at ws://127.0.0.1:13522/phIZ-tCvqZQ=/ws
Connected to the VM Service.
flutter: extractAssetOrFile directory: D:\Users\aiden.guo\AppData\Roaming\com.example\run_example\flet\app
flutter: Start unpacking archive: app/app.zip
flutter: Finished unpacking application archive in 0:00:05.363893
starting
Hello from Python program!
HELLO!
Original     : 26 b'This is the original text.'
Compressed   : 62 b'425a683931415926535916be35a600000293804001040022e59c402000314c000111e93d434da223028cf9e73148cae0a0d6ed7f17724538509016be35a6'
Decompressed : 26 b'This is the original text.'
start check
exePath: D:\github_code\serious-python\src\serious_python\example\run_example\build\windows\x64\runner\Debug\run_example.exe
exeDir: D:\github_code\serious-python\src\serious_python\example\run_example\build\windows\x64\runner\Debug
appPath: D:\Users\aiden.guo\AppData\Roaming\com.example\run_example\flet\app\main.py
PYTHONPATH: D:\Users\aiden.guo\AppData\Roaming\com.example\run_example\flet\app;D:\Users\aiden.guo\AppData\Roaming\com.example\run_example\flet\app\__pypackages__;D:\github_code\serious-python\src\serious_python\example\run_example\build\windows\x64\runner\Debug\DLLs;D:\github_code\serious-python\src\serious_python\example\run_example\build\windows\x64\runner\Debug\Lib;D:\github_code\serious-python\src\serious_python\example\run_example\build\windows\x64\runner\Debug\Lib\site-packages
env_var: RESULT_FILENAME=C:\Users\aiden.guo\AppData\Local\Temp\run_example7eec0265\out.txt
env_var: RESULT_VALUE=JtcxBxeHxYdnsgbyndWJ
sync: false
Running Python program asynchronously...Traceback (most recent call last):
  File "D:\Users\aiden.guo\AppData\Roaming\com.example\run_example\flet\app\main.py", line 86, in <module>
    test_lru()
  File "D:\Users\aiden.guo\AppData\Roaming\com.example\run_example\flet\app\main.py", line 41, in test_lru
    from lru import LRU
  File "D:\Users\aiden.guo\AppData\Roaming\com.example\run_example\flet\app\__pypackages__\lru\__init__.py", line 1, in <module>
    from ._lru import LRU as LRU  # noqa: F401
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
ModuleNotFoundError: No module named 'lru._lru'

It really confused me because I think the same app.zip is used in both release and debug mode, it should contain the lru dependency.
I submitted an issue #116 yesterday about that I can't compile the app automatically, I manually moved some files, I don't know if it caused the problem.

Ngôn ngữ chính
Dart
Star
325
Fork
46
Merge trung bình
14 giờ 53 phút
Pull request đã merge (30 ngày)
5

Chuẩn bị môi trường

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của flet-dev/serious-python

Tất cả issue của flet-dev/serious-python

Issue tương tự

Thêm issue về Dart

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.