Desktop app cannot change keys after the first Setup

オープン
#564 コメント 0 件 リアクション 0 件 担当者 1 名 GitHub で見る

メンテナーはふだん 1 日以内に返信

@Patriciaath999 がすでに取り組んでいます。

2026年10月31日 から。

  • #569 @Patriciaath999 による — オープン

評価

難易度
5/5
見積もり時間
1週間以上
初心者へのやさしさ
35/100
issue の種類
機能追加
明瞭さ
おおむね明確
活発さ
活発
技術スタック
rust
領域
desktop, security

調査の方向性

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.

索引モデルが issue の本文から書いたものです。

説明

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?

主要言語
Rust
スター
215
フォーク
141
平均マージ
1日 12時間
マージ済み PR(30日)
230

環境構築

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

sysprog21/codetrial のほかの issue

sysprog21/codetrial の issue をすべて見る

似ている issue

Rust の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。