langflow-ai/langflow · error · Error
HTTP error! status: ${response.status}
Error message
HTTP error! status: ${response.status} What it means
Generic 500 raised by the catch-all handler of the project-tools listing endpoint in the project MCP API (mcp_projects.py). Any exception while collecting tools, decrypting auth settings, or constructing AuthSettings bubbles up here and the raw exception text is echoed to the client. Typical causes are malformed/undecryptable auth_settings on the Folder row or Pydantic validation failures in AuthSettings.
Source
Thrown at src/frontend/src/controllers/API/index.ts:94
},
tags: string[],
publicFlow = false,
): Promise<FlowType> {
try {
const response = await api.post(`${getBaseUrl()}store/components/`, {
name: newFlow.name,
data: newFlow.data,
description: newFlow.description,
is_component: newFlow.is_component,
parent: newFlow.parent,
tags: tags,
private: !publicFlow,
status: publicFlow ? "Public" : "Private",
last_tested_version: newFlow.last_tested_version,
});
if (response.status !== 201) {
throw new Error(`HTTP error! status: ${response.status}`);
}
return response?.data;
} catch (error) {
console.error(error);
throw error;
}
}
export async function getStoreComponents({
component_id = null,
page = 1,
limit = 9999999,
is_component = null,
sort = "-count(liked_by)",
tags = [],
liked = null,
isPrivate = null,
search = null,View on GitHub (pinned to 976ec789d2)
Solutions
- Read the server log: the handler calls logger.aexception with 'Error listing project tools: {e}' — the traceback names the exact field or operation that failed.
- Inspect the project row's auth_settings JSON in the DB for stale/unexpected keys; re-save the MCP auth settings from the UI to rewrite them in the current schema.
- If decryption fails after a secret-key change, clear the stored auth settings for that project and re-enter credentials.
- If AuthSettings validation is the cause, align the masked payload with the current AuthSettings model (only pass fields it defines).
Defensive patterns
Strategy: try-catch
Try / catch
try:
tools = await client.list_project_tools(project_id)
except httpx.HTTPStatusError as e:
if e.response.status_code == 500:
log_server_detail(e.response.json().get("detail")) # echoes the inner exception
raise Prevention
- Always re-save MCP auth settings from the UI after upgrading Langflow so the stored schema matches AuthSettings.
- Avoid rotating LANGFLOW_SECRET_KEY without a plan for re-encrypting stored secrets.
- Surface the 500 detail in bug reports — it contains the underlying exception text.
When it happens
Trigger: GET /api/v1/mcp/projects/{project_id}/tools (or the list-tools route ending at this handler) where: project.auth_settings contains keys not accepted by AuthSettings, decryption of stored secrets fails (changed SECRET_KEY), or the tool-collection coroutine raises.
Common situations: Rotating LANGFLOW_SECRET_KEY so previously encrypted oauth_client_secret/api_key values no longer decrypt; upgrading Langflow so AuthSettings gained/renamed fields while old DB rows keep the old shape; a component in the project failing to import during tool discovery.
Related errors
- Failed to load models. Please check your provider credential
- Failed to reload bundle
- Failed to download files: ${response.statusText}
- Failed to download flows: ${response.statusText}
- Failed to delete MCP Server
AI-assisted analysis of langflow-ai/langflow@976ec789d2 (2026-08-14).
Data as JSON: /api/errors/467cdef5029da46a.
Report an issue: GitHub.