@@ -451,6 +451,7 @@ export default class StartWorkspace extends React.Component<StartWorkspaceProps,
451
451
let phase : StartPhase | undefined = StartPhase . Preparing ;
452
452
let title = undefined ;
453
453
let isTimedOut = false ;
454
+ let isStoppingOrStopped = false ;
454
455
let statusMessage = ! ! error ? undefined : < p className = "text-base text-gray-400" > Preparing workspace …</ p > ;
455
456
const contextURL = ContextURL . getNormalizedURL ( this . state . workspace ) ?. toString ( ) ;
456
457
const useLatest = ! ! this . state . workspaceInstance ?. configuration ?. ideConfig ?. useLatest ;
@@ -624,6 +625,7 @@ export default class StartWorkspace extends React.Component<StartWorkspaceProps,
624
625
625
626
// Stopping means that the workspace is currently shutting down. It could go to stopped every moment.
626
627
case "stopping" :
628
+ isStoppingOrStopped = true ;
627
629
if ( isPrebuild ) {
628
630
return (
629
631
< StartPage title = "Prebuild in Progress" >
@@ -661,6 +663,7 @@ export default class StartWorkspace extends React.Component<StartWorkspaceProps,
661
663
662
664
// Stopped means the workspace ended regularly because it was shut down.
663
665
case "stopped" :
666
+ isStoppingOrStopped = true ;
664
667
phase = StartPhase . Stopped ;
665
668
if ( this . state . hasImageBuildLogs ) {
666
669
const restartWithDefaultImage = ( event : React . MouseEvent ) => {
@@ -712,7 +715,12 @@ export default class StartWorkspace extends React.Component<StartWorkspaceProps,
712
715
break ;
713
716
}
714
717
return (
715
- < StartPage phase = { phase } error = { error } title = { title } showLatestIdeWarning = { ! isTimedOut && useLatest } >
718
+ < StartPage
719
+ phase = { phase }
720
+ error = { error }
721
+ title = { title }
722
+ showLatestIdeWarning = { ! isTimedOut && ! isStoppingOrStopped && useLatest }
723
+ >
716
724
{ statusMessage }
717
725
</ StartPage >
718
726
) ;
0 commit comments