If POST takes longer than 8 seconds, installer immediately gives up rather than continuing to wait
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 3/5
- Thời gian dự kiến
- 1-2 ngày
- Mức phù hợp với người mới
- 45/100
- Loại issue
- Lỗi
- Độ rõ ràng
- Khá rõ ràng
- Mức độ hoạt động
- Đình trệ
- Công nghệ
- javascript, python
Hướng nghiên cứu
Xem xét mã frontend của trình cài đặt để xử lý timeout của XMLHttpRequest, có thể nằm trong tệp JavaScript quản lý các yêu cầu POST. Logic quét backend nằm trong Python; kiểm tra các hàm phát hiện đường dẫn trò chơi. Issue đề cập đến các commit cho timeout quét và nút hủy; hãy xem lại những thay đổi đó để hiểu trạng thái hiện tại. Xác định cách sửa đổi timeout để không hủy yêu cầu và điều chỉnh thông báo lỗi cho phù hợp.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
We had an issue where a user had an infinite loading screen on the part of the installer which autodetects game paths.
There were no relevant errors on the install log, but the browser showed a POST error, as if the python side never responded.
What actually happened was that the python side had no errors, but it took longer than 8 seconds to respond. Because the HTML side gives up after 8 seconds, the HTML side raised an error, but the Python side did not. This was because I implemented the timeout using the native XMLHttpRequest timeout functionality, which cancels the POST after a timeout (...or at least I think that's how it works).
The installer should really show an error after 8 seconds (or however many seconds), but continue to listen for the response.
The error message should also be adjusted to tell the user to wait some time in case the operation just takes a long time.
I actually had hard-coded that if the request type was showFileChooser, there was no POST timeout, but I feel hard-coding specific requests to not the right way to do this.
A related issue is why the game scanning step took so long - the user was using a SSD, and didn't have that many games installed on their computer. It could be:
- my installer is doing something really bad and taking ages
- your computer is slow for some reason
- there is a game which causes the installer's scanning algorithm to give worst-case behavior
The scanning should really give up if it took more than a certain amount of time to scan, as even if scanning fails, the installer can still be used. Or perhaps have a per-directory scan timeout.
The installer also doesn't print how long/which folders were scanned,
- Fix POST timeout behavior
- Investigate slow game scanning
- Set a timeout on game scanning (make sure to only enable this when scanning many paths, not when checking a user-specified path) 4efd0b9f3ef1691ff3c4ac8ec281c343587184da
- Add button to cancel scanning (currently becomes greyed out forever if scanning never finishes) e6371a58aa81bcc1fcbe6ad2bf75cd215feaac26
- Ngôn ngữ chính
- JavaScript
- Star
- 214
- Fork
- 12
- Chỉ số merge pull request
- Không có pull request nào được merge trong 30 ngày
Chuẩn bị môi trường
- Không có Dockerfile hay tệp Docker Compose
- Không có mẫu pull request
- Đọc hướng dẫn đóng góp
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- 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.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của 07th-mod/python-patcher
-
SSL/TLS Errors Index PageĐang mở
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 75/100
07th-mod/python-patcher#214 ·
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 65/100
07th-mod/python-patcher#193 ·
-
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 75/100
07th-mod/python-patcher#137 ·
-
enhancement help wanted
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 70/100
07th-mod/python-patcher#83 ·
-
Missing cert on Fedora LinuxĐang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 65/100
07th-mod/python-patcher#80 · 11 bình luận ·
Tất cả issue của 07th-mod/python-patcher
Issue tương tự
-
bug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 72/100
capricorn86/happy-dom#2485 ·
Maintainer thường phản hồi trong vòng 2 ngày
-
area:space-accuracy good first issue track:data
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 85/100
Sara-Managed-Projects/space-radar#904 ·
Maintainer thường phản hồi trong vòng 1 ngày