ZhuLinsen/daily_stock_analysis · error · GenerationError

backend_not_configured

backend_not_configured

Error message

backend_not_configured at configuration for backend {backend}

What it means

Error "backend_not_configured at configuration for backend {backend}" thrown in ZhuLinsen/daily_stock_analysis.

Source

Thrown at src/services/generation_backend_status_service.py:354

            "mode": request.mode,
            "message": "生成后端冒烟测试通过",
            "status": status,
        }

    def _primary_backend_id(self) -> str:
        return normalize_backend_id(self._effective_map.get("GENERATION_BACKEND"), default=LITELLM_BACKEND_ID)

    def _normalize_smoke_request(
        self,
        *,
        backend_id: Optional[str],
        mode: str,
        timeout_seconds: Optional[float],
    ) -> _SmokeRequest:
        config = self._build_backend_config()
        requested_backend = normalize_backend_id(backend_id, default=resolve_generation_backend_id(config))
        if requested_backend not in SUPPORTED_GENERATION_BACKENDS:
            raise GenerationError(
                error_code=GenerationErrorCode.BACKEND_NOT_CONFIGURED,
                stage="configuration",
                retryable=False,
                fallbackable=False,
                backend=requested_backend,
                details={
                    "field": "backend_id",
                    "requested_backend": requested_backend,
                    "supported_backends": sorted(SUPPORTED_GENERATION_BACKENDS),
                },
            )
        normalized_mode = str(mode or "json").strip().lower() or "json"
        if normalized_mode not in {"text", "json"}:
            raise GenerationError(
                error_code=GenerationErrorCode.UNSAFE_CONFIG,
                stage="configuration",
                retryable=False,
                fallbackable=False,

View on GitHub (pinned to 5159bd72e8)

Solutions

  1. Configure the named generation backend in .env (API key, model, base URL) before enabling it.
  2. Run the backend status/config check to see which required settings are missing.
  3. Remove the backend from the active route list if it is not meant to be used.

When it happens

Trigger: Thrown at src/services/generation_backend_status_service.py:354 when the library encounters an invalid state.

Common situations: Reported by the generation backend status check when the requested backend has no configuration; occurs when the user probes status for a backend whose API key/base URL was never set.


AI-assisted analysis of ZhuLinsen/daily_stock_analysis@5159bd72e8 (2026-08-15). Data as JSON: /api/errors/d86a4e249fe406e9. Report an issue: GitHub.