Conversation
|
/gemini review |
There was a problem hiding this comment.
Code Review
This pull request modifies the update process in UpdateHandler.java to ensure a clean application shutdown and data persistence before applying updates. It introduces logic to wait for Controllers.onApplicationStop() to execute on the JavaFX thread and calls FileSaver.waitForAllSaves() to prevent data loss. The review feedback correctly identifies a potential hang if onApplicationStop() throws an exception and suggests using a try-finally block to ensure the CompletableFuture always completes.
|
@codex review |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 12e7e18455
ℹ️ 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".
|
|
||
| Platform.runLater(() -> { | ||
| try { | ||
| Controllers.onApplicationStop(); |
There was a problem hiding this comment.
Delay app-stop state changes until update launch succeeds
Calling Controllers.onApplicationStop() here mutates global UI shutdown state before requestUpdate(...) is attempted. If requestUpdate fails with IOException (for example, jar verification or ProcessBuilder.start() failure), the catch path shows an error and keeps the current process alive, but onApplicationStop() has already disabled window geometry tracking (Controllers.onApplicationStop nulls the stage tracking fields), so the rest of the session and final exit can no longer persist window position/size.
Useful? React with 👍 / 👎.
No description provided.