-
Notifications
You must be signed in to change notification settings - Fork 4
Web: have a way to let people know that a newer version of OpenCOR is available #402
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
Adds a web-app update notification mechanism so users are informed when a newer OpenCOR build is available and can reload to update (Fixes #400).
Changes:
- Introduces periodic version checking in the web app via a generated
assets/version.json. - Adds a “New version available!” link to the main menu with a confirmation dialog to reload.
- Updates build scripts to generate
dist/assets/version.jsonand bumps package versions.
Reviewed changes
Copilot reviewed 7 out of 7 changed files in this pull request and generated 5 comments.
Show a summary per file
| File | Description |
|---|---|
src/renderer/src/components/OpenCOR.vue |
Starts the periodic web version check after libOpenCOR finishes initializing. |
src/renderer/src/components/MainMenu.vue |
Displays update CTA in the menubar and prompts before reloading. |
src/renderer/src/common/version.ts |
Implements web-only version polling and exposes update state + reload helper. |
src/renderer/src/common/settings.ts |
Comment wording tweak (“Web version…”). |
src/renderer/scripts/generate.version.js |
New build script intended to emit dist/assets/version.json. |
src/renderer/package.json |
Runs the version generation script after renderer build; bumps version. |
package.json |
Runs the version generation script after web build; bumps version. |
Comments suppressed due to low confidence (1)
src/renderer/src/common/version.ts:118
- This TODO is now inaccurate:
latestVersionis used byMainMenu.vueto display the version in the update prompt. Please remove or update this comment to avoid misleading future changes.
export { latestVersion, reloadApp, startCheck, updateAvailable };
// TODO: latestVersion is NOT currently used in the Web app.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
Copilot reviewed 8 out of 8 changed files in this pull request and generated 5 comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
29c4fb1 to
6494b1f
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
Copilot reviewed 8 out of 8 changed files in this pull request and generated 4 comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
d559ad3 to
ffd1cd8
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
Copilot reviewed 10 out of 10 changed files in this pull request and generated 5 comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
Copilot reviewed 10 out of 10 changed files in this pull request and generated 2 comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
Copilot reviewed 10 out of 10 changed files in this pull request and generated 2 comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| import * as vue from 'vue'; | ||
|
|
||
| import packageJson from '../../package.json' with { type: 'json' }; | ||
|
|
Copilot
AI
Feb 8, 2026
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
import ... with { type: 'json' } introduces import attributes syntax that isn’t used elsewhere in the renderer (other files import package.json directly) and can be less compatible with the current Vite/TS pipeline. Consider switching to the same JSON import style used in the Vue components (or otherwise standardize on one approach) to avoid build/runtime differences.
Fixes #400.