fix(startup): Fix wizard response flow and first-run log noise#1076
fix(startup): Fix wizard response flow and first-run log noise#1076
Conversation
Return immediately after wizard redirect to avoid double header sends. Use changeMasterPassword in first-time wizard to avoid AlreadySetPasswordException. Treat missing first-run bookmark/uptime files as normal fallback conditions. Update wizard unit test assertions for redirect-only success path.
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 32829dac3b
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
src/main/java/network/crypta/clients/http/FirstTimeWizardNewToadlet.java
Show resolved
Hide resolved
Load master keys from disk with oldPassword when master.keys exists but in-memory keys are null. Preserve existing password-change flow and add regression test for the null-keys path.
|
@codex review |
|
Codex Review: Didn't find any major issues. 🚀 ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
|


Summary
FirstTimeWizardNewToadletPOST flow to return immediately after redirect, preventing duplicate header writes (Already sent headers!).changeMasterPassword("", newPassword, true)so it does not throwAlreadySetPasswordExceptionwhen keys are already initialized.bookmarks.datand missing uptime history files as normal fallback cases.How to test
./gradlew test --tests network.crypta.clients.http.FirstTimeWizardNewToadletTest --tests network.crypta.clients.http.bookmark.BookmarkManagerTest --tests network.crypta.node.UptimeEstimatorTest./gradlew testAlready sent headers!error is logged.bookmarks.datand uptime files no longer emit misleading error-level startup logs.Notes
release/2(per request).