continuedev/continue · error · Error
Failed to sync remote config (HTTP ${response.status}): ${re
Error message
Failed to sync remote config (HTTP ${response.status}): ${response.statusText} What it means
The client stub for syncing remote config GETs the config endpoint with a Bearer userToken; on a non-OK response it throws with status and statusText. Auth failures (401), missing configs (404), or hub errors (5xx) all surface here.
Source
Thrown at core/continueServer/stubs/client.ts:42
getUserToken(): string | undefined {
return this.userToken;
}
get connected(): boolean {
return this.url !== undefined && this.userToken !== undefined;
}
public async getConfig(): Promise<{ configJson: string }> {
const userToken = await this.userToken;
const response = await fetch(new URL("sync", this.url).href, {
method: "GET",
headers: {
Authorization: `Bearer ${userToken}`,
},
});
if (!response.ok) {
throw new Error(
`Failed to sync remote config (HTTP ${response.status}): ${response.statusText}`,
);
}
const data = await response.json();
return data;
}
public async getFromIndexCache<T extends ArtifactType>(
keys: string[],
artifactId: T,
repoName: string | undefined,
): Promise<EmbeddingsCacheResponse<T>> {
if (repoName === undefined) {
console.warn(
"No repo name provided to getFromIndexCache, this may cause no results to be returned.",
);
}
View on GitHub (pinned to 5522c6f44c)
Solutions
- Verify the token: decode the JWT and check exp; re-authenticate to get a fresh userToken
- Confirm the config id/URL points at the correct hub environment
- Retry on 5xx; check hub status if failures persist
Defensive patterns
Strategy: retry
Validate before calling
function isLikelyValidToken(t: string): boolean {
try { const { exp } = JSON.parse(Buffer.from(t.split('.')[1], 'base64').toString()); return Date.now() / 1000 < exp; }
catch { return false; }
} Try / catch
try { return await getConfig(userToken); }
catch (e) {
if (/HTTP 401/.test(e.message)) { userToken = await reauthenticate(); return getConfig(userToken); }
if (/HTTP 5\d\d/.test(e.message)) { await backoff(); return getConfig(userToken); }
throw e;
} Prevention
- Refresh tokens before expiry
- Pin the correct hub environment per build
- Retry with backoff on 5xx only
When it happens
Trigger: Calling getConfig with an invalid/expired userToken (401), a user/config id that no longer exists on the hub (404), or hub downtime (5xx).
Common situations: Stale token after re-login, token from a different environment (dev vs prod hub), config deleted on the hub side, or hub migration changing endpoints.
Related errors
- Failed to fetch Google search results: ${response.statusText
- Greptile token not found.
- GitHub token not found.
- HTTP error! status: ${response.status}
- HTTP ${resp.status} ${resp.statusText}
AI-assisted analysis of continuedev/continue@5522c6f44c (2026-08-27).
Data as JSON: /api/errors/1ef4fc487b3fe50c.
Report an issue: GitHub.