mirror of
https://github.com/Crosstalk-Solutions/project-nomad.git
synced 2026-04-04 15:56:16 +02:00
fix(Settings): improve user guidance during system update
This commit is contained in:
parent
ba6528549c
commit
8ae2741ea5
|
|
@ -1,5 +1,16 @@
|
||||||
# Release Notes
|
# Release Notes
|
||||||
|
|
||||||
|
## Unreleased
|
||||||
|
|
||||||
|
### Features
|
||||||
|
|
||||||
|
### Bug Fixes
|
||||||
|
- **Settings**: Fix potential stale cache issue when checking for system updates
|
||||||
|
- **Settings**: Improve user guidance during system updates
|
||||||
|
|
||||||
|
### Improvements
|
||||||
|
|
||||||
|
|
||||||
## Version 1.25.0 - February 12, 2026
|
## Version 1.25.0 - February 12, 2026
|
||||||
|
|
||||||
### Features
|
### Features
|
||||||
|
|
|
||||||
|
|
@ -231,6 +231,7 @@ export default function SystemUpdatePage(props: {
|
||||||
const [logs, setLogs] = useState<string>('')
|
const [logs, setLogs] = useState<string>('')
|
||||||
const [email, setEmail] = useState('')
|
const [email, setEmail] = useState('')
|
||||||
const [versionInfo, setVersionInfo] = useState(props.system)
|
const [versionInfo, setVersionInfo] = useState(props.system)
|
||||||
|
const [showConnectionLostNotice, setShowConnectionLostNotice] = useState(false)
|
||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
if (!isUpdating) return
|
if (!isUpdating) return
|
||||||
|
|
@ -243,6 +244,9 @@ export default function SystemUpdatePage(props: {
|
||||||
}
|
}
|
||||||
setUpdateStatus(response)
|
setUpdateStatus(response)
|
||||||
|
|
||||||
|
// If we can connect again, hide the connection lost notice
|
||||||
|
setShowConnectionLostNotice(false)
|
||||||
|
|
||||||
// Check if update is complete or errored
|
// Check if update is complete or errored
|
||||||
if (response.stage === 'complete') {
|
if (response.stage === 'complete') {
|
||||||
// Give a moment for the new container to fully start
|
// Give a moment for the new container to fully start
|
||||||
|
|
@ -255,6 +259,8 @@ export default function SystemUpdatePage(props: {
|
||||||
}
|
}
|
||||||
} catch (err) {
|
} catch (err) {
|
||||||
// During container restart, we'll lose connection - this is expected
|
// During container restart, we'll lose connection - this is expected
|
||||||
|
// Show a notice to inform the user that this is normal
|
||||||
|
setShowConnectionLostNotice(true)
|
||||||
// Continue polling to detect when the container comes back up
|
// Continue polling to detect when the container comes back up
|
||||||
console.log('Polling update status (container may be restarting)...')
|
console.log('Polling update status (container may be restarting)...')
|
||||||
}
|
}
|
||||||
|
|
@ -414,6 +420,16 @@ export default function SystemUpdatePage(props: {
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
)}
|
)}
|
||||||
|
{isUpdating && showConnectionLostNotice && (
|
||||||
|
<div className="mb-6">
|
||||||
|
<Alert
|
||||||
|
type="info"
|
||||||
|
title="Connection Temporarily Lost (Expected)"
|
||||||
|
message="You may see error notifications while the backend restarts during the update. This is completely normal and expected. Connection should be restored momentarily."
|
||||||
|
variant="solid"
|
||||||
|
/>
|
||||||
|
</div>
|
||||||
|
)}
|
||||||
<div className="bg-white rounded-lg border shadow-md overflow-hidden">
|
<div className="bg-white rounded-lg border shadow-md overflow-hidden">
|
||||||
<div className="p-8 text-center">
|
<div className="p-8 text-center">
|
||||||
<div className="flex justify-center mb-4">{getStatusIcon()}</div>
|
<div className="flex justify-center mb-4">{getStatusIcon()}</div>
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user