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

Show local time in past attempt labels

Đã đóng Phù hợp với người mới
#317 2 bình luận 1 reaction 1 người được giao Xem trên GitHub

Maintainer thường phản hồi trong vòng 1 ngày

@jin11109 đang làm issue này rồi.

Từ ngày 15/10/2026.

  • #338 của @jin11109 — đã merge

Đánh giá

Độ khó
2/5
Thời gian dự kiến
1-3 giờ
Mức phù hợp với người mới
78/100
Loại issue
Lỗi
Độ rõ ràng
Đặc tả rõ ràng
Mức độ hoạt động
Sôi nổi
Công nghệ
javascript
Lĩnh vực
frontend

Hướng nghiên cứu

Lỗi nằm ở renderAttemptHistory trong web/app.js, hàm này định dạng nhãn của từng lần thử trước đó bằng toLocaleDateString() dù lần thử vẫn giữ dấu thời gian của nó. Hãy đọc hàm đó trước, rồi đọc bài kiểm thử hồi quy trên trình duyệt bao phủ lịch sử tài khoản và thiết bị với nhãn sắp xếp từ mới nhất đến cũ nhất. Hoàn thành khi nhãn bao gồm giờ địa phương, trường hợp UTC rơi vào ngày địa phương kế tiếp vượt qua, và các bài kiểm thử lobby đều đạt.

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

Mô tả

Past attempts shows only the date in each row label. Two interviews completed on the same day with the same problem, language, and verdict therefore have identical labels, making it difficult to choose the intended report.

I reproduced this on main at 6b6cdfe using synthetic history in Chromium with the Asia/Taipei time zone and en-US locale. Attempts saved at 2026-01-01T16:15:00Z and 2026-01-02T10:30:00Z both display "1/2/2026 · Same problem · Python · HIRE". The expected labels include their local times, 12:15:00 AM and 6:30:00 PM.

The cause is renderAttemptHistory in web/app.js, which uses toLocaleDateString() even though each attempt retains its timestamp. A local proof of concept uses toLocaleString(), matching the date and time format already used by the Download report accessible names. PR #313 addresses downloaded filenames; this proposal only changes the visible history labels.

The browser regression test covers both account history and device history, checks newest-first labels, and includes a UTC timestamp that falls on the next local date. Both cases failed before the fix. After the fix, all 139 lobby tests passed with no skips. The source build and full test gate are still being checked; I am not claiming they pass.

Ngôn ngữ chính
Rust
Star
160
Fork
64
Merge trung bình
1 ngày 12 giờ
Pull request đã merge (30 ngày)
124

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 sysprog21/codetrial

Tất cả issue của sysprog21/codetrial

Issue tương tự

Thêm issue về Rust

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.