{"record":{"id":"b51605a0de8c88df","repo":"bytedance/deer-flow","slug":"failed-to-load-features-res-statustext","errorCode":null,"errorMessage":"Failed to load features: ${res.statusText}","messagePattern":"Failed to load features: (.+?)","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"frontend/src/core/features/api.ts","lineNumber":12,"sourceCode":"import { fetch } from \"@/core/api/fetcher\";\nimport { getBackendBaseURL } from \"@/core/config\";\n\nexport interface FeaturesResponse {\n  agents_api: { enabled: boolean };\n  browser_control?: { enabled: boolean };\n}\n\nexport async function fetchFeatures(): Promise<FeaturesResponse> {\n  const res = await fetch(`${getBackendBaseURL()}/api/features`);\n  if (!res.ok) {\n    throw new Error(`Failed to load features: ${res.statusText}`);\n  }\n  return (await res.json()) as FeaturesResponse;\n}\n\nexport async function fetchAgentsApiEnabled(): Promise<boolean> {\n  return (await fetchFeatures()).agents_api.enabled;\n}\n\nexport async function fetchBrowserControlEnabled(): Promise<boolean> {\n  return (await fetchFeatures()).browser_control?.enabled ?? false;\n}\n","sourceCodeStart":1,"sourceCodeEnd":24,"githubUrl":"https://github.com/bytedance/deer-flow/blob/1dd6ba1acb03700589994b0366c5d1c7d05e2eff/frontend/src/core/features/api.ts#L1-L24","documentation":"Raised when timeout_seconds is not finite (NaN/inf) or is <= 0. The value feeds the HTTP client's per-request timeout; non-positive or non-finite values would either be rejected by the HTTP layer or disable timeouts entirely, so config validation rejects them up front.","triggerScenarios":"Setting timeout_seconds: 0 or a negative number, or a templated value that expands to .nan/.inf in YAML. int()/float() coercion of malformed values also lands here. Validation runs during _validate.","commonSituations":"Templated YAML expanding to .nan; setting 0 to mean 'no timeout'; huge values overflowing to inf; template leaving the value unset and a placeholder string failing coercion.","solutions":["Set a sane positive finite timeout, e.g. timeout_seconds: 30 (the default).","Make templating fail when the value is unset instead of emitting nan/inf.","For slow servers raise it moderately (60-120) rather than trying to disable it."],"exampleFix":"# before\nbackend_config:\n  timeout_seconds: 0  # or .nan\n\n# after\nbackend_config:\n  timeout_seconds: 30","handlingStrategy":"validation","validationCode":"from math import isfinite\n\n\ndef check_timeout(value: float) -> None:\n    assert isfinite(value) and value > 0, 'timeout_seconds must be finite and > 0'","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Use explicit numeric literals (30, 60) in config; avoid templated math that can produce inf or nan.","Never use 0 to mean 'no timeout'; pick a generous finite value instead.","Lint config for non-finite numerics before deploy."],"tags":["openviking","configuration","validation","timeout"],"backgroundTag":null,"analyzedSha":"1dd6ba1acb03700589994b0366c5d1c7d05e2eff","analyzedAt":"2026-08-14T21:20:34.804Z","schemaVersion":2},"datasetVersion":"2026-08-15T17:31:12.345Z"}