Desktop app cannot change keys after the first Setup

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

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

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

Từ ngày 31/10/2026.

  • #569 của @Patriciaath999 — đang mở

Đánh giá

Độ khó
5/5
Thời gian dự kiến
Hơn một tuần
Mức phù hợp với người mới
35/100
Loại issue
Tính năng
Độ rõ ràng
Khá rõ ràng
Mức độ hoạt động
Sôi nổi
Công nghệ
rust
Lĩnh vực
desktop, security

Hướng nghiên cứu

Start by reading src/main.rs:446-454, desktop/src/server.rs:118,235, and desktop/src/main.rs:294-330 to trace Setup, the launch save code, child shutdown, and exit handling. Decide how the shell securely obtains or generates the save code, then distinguish an intentional restart from a crash and preserve the refusal while an interview is running or reporting. Done means the desktop Setup page can change keys, restart the child successfully, and retain the web half’s interview-safety behavior.

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

Mô tả

The desktop app still offers no way to change keys after the first Setup. #528 reopens Setup from the lobby for a standalone loopback web server and leaves the desktop app's child server out on purpose: run_web passes !launched_as_child when it builds the Setup context (src/main.rs:446), and the shell launches its child with CODETRIAL_EXIT_WITH_STDIN (desktop/src/server.rs:118), so the lobby there never shows Change keys. A desktop user who skipped the Google key still has to find codetrial.env.local under %LOCALAPPDATA%\org.sysprog21.codetrial, edit it by hand and restart the app.

This is the desktop half split out of #513. It needs three things:

  1. Change keys in the child server. #528 requires a save code generated at each launch and printed only to the terminal that started the server (src/main.rs:454). The desktop app has no terminal, so the shell has to obtain that code and supply it to the page, or the child needs another proof only the shell holds.
  2. A restart that is not a failure. After Setup writes the file, the shell has to stop the child with Server::stop (desktop/src/server.rs:235) and call launch again (desktop/src/main.rs:294). Today any child exit reaches Status::Exited, which shows the failure page unless the app is quitting (desktop/src/main.rs:330), so the restart has to be told apart from a crash.
  3. The same refusal as the web half. #528 refuses a save while a local interview is running or still writing its report; the desktop restart must keep that, so it never ends an interview in progress.

Which should carry the save code to the desktop page: the shell reading it from the child's output, or the shell generating it and passing it to the child at launch?

Ngôn ngữ chính
Rust
Star
215
Fork
141
Merge trung bình
1 ngày 10 giờ
Pull request đã merge (30 ngày)
230

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.