You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
SessionOpener.sendPing does not call onCompleted when retry limit is exhausted #17143
In SessionOpener.sendPing(), when the ping loop exhausts its maxRetries without successfully reaching the session, it logs a warning and returns false to stop the RepeatingCommand — but never calls the onCompleted callback.
// SessionOpener.java:216-219if (retries_++ > maxRetries)
{
Debug.logWarning("Error connecting with session.");
returnfalse; // onCompleted never called
}
Impact
This means ApplicationQuit.onSuspendAndRestartImpl()'s onRestartComplete operation is never executed, so:
RestartStatusEvent.RESTART_COMPLETED is never fired, leaving any listeners (e.g. Application.resumeClientStateUpdater(), RemoteServer.restartInProgress_) in stale state.
The progress indicator is never dismissed.
Suggested Fix
Call onCompleted before returning false on retry exhaustion:
if (retries_++ > maxRetries)
{
Debug.logWarning("Error connecting with session.");
onCompleted.execute();
returnfalse;
}
Context
Discovered during review of #17141. In practice this is unlikely to trigger because the ping loop targets a restarting local session, but it represents a gap in the completion contract that could cause hard-to-diagnose state issues.
Activity
Address review feedback on INVALID_CLIENT_ID suppression
Suppress INVALID_CLIENT_ID disconnect during R session restart (#17141)
Add NEWS.md entry for rstudio#17143
Call onCompleted when SessionOpener retry limit is exhausted (rstudio…
ensure sendPing onCompleted fires exactly once (#17906)