feat(spx-gui): notification for new versions of XBuilder#2842
feat(spx-gui): notification for new versions of XBuilder#2842nighca merged 14 commits intogoplus:devfrom
Conversation
Summary of ChangesHello @cn0809, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed! This pull request introduces a crucial user experience enhancement by providing timely notifications for new application versions. It ensures users are always on the latest build by gently prompting them to refresh their browser, thereby improving access to new features and bug fixes without manual intervention. Highlights
🧠 New Feature in Public Preview: You can now enable Memory to help Gemini Code Assist learn from your team's feedback. This makes future code reviews more consistent and personalized to your project's style. Click here to enable Memory in your admin console. Changelog
Activity
Using Gemini Code AssistThe full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips. Invoking Gemini You can request assistance from Gemini at any point by creating a comment using either
Customization To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a Limitations & Feedback Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here. You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension. Footnotes
|
There was a problem hiding this comment.
Code Review
This pull request introduces a valuable feature for notifying users about new application versions. The implementation is well-structured, utilizing ETag checking for efficiency and asynchronous component loading. I've identified a logic error in event handling that could cause a function to be called twice, and a couple of opportunities to enhance code clarity and robustness, particularly concerning magic numbers and behavior in multi-tab environments. My specific comments are detailed below.
There was a problem hiding this comment.
Pull request overview
This PR implements an update notification system for XBuilder to detect and notify users when a new version of the application is deployed. The system checks for updates by comparing the ETag of the index.html file and prompts users to reload the page when an update is available.
Changes:
- Added update checker utility that periodically checks for new versions via ETag comparison
- Implemented UpdateNotification dialog component to prompt users to reload
- Added
isDevflag to environment utilities to disable update checking in development mode
Reviewed changes
Copilot reviewed 5 out of 5 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
| spx-gui/src/utils/env.ts | Added isDev flag to identify development mode |
| spx-gui/src/components/app/update-checker.ts | Core update checking logic using ETag-based version detection |
| spx-gui/src/components/app/update-checker.test.ts | Comprehensive test suite for update checker functionality |
| spx-gui/src/components/app/UpdateNotification.vue | Dialog component that displays update notification and handles reload |
| spx-gui/src/App.vue | Integrated UpdateNotification component as async component |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
|
/review |
…ndling - Skip update check when navigator.onLine is false - Remove consecutive failure counter and auto-disable logic - Stop checker from caller side (UpdateNotificationWrapper) on update detected - Use capture() for error reporting instead of console.error - Rename UpdateNotificationProvider to UpdateNotificationWrapper Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
close: #2575