ZhuLinsen/daily_stock_analysis · error · GenerationError

schema_validation_failed

schema_validation_failed

Error message

schema_validation_failed at smoke_validation for backend generation_backend

What it means

Error "schema_validation_failed at smoke_validation for backend generation_backend" thrown in ZhuLinsen/daily_stock_analysis.

Source

Thrown at src/services/generation_backend_status_service.py:418

            self._json_smoke_validator(result.text)
        else:
            self._text_smoke_validator(result.text)

    @classmethod
    def _json_smoke_validator(cls, text: str) -> None:
        try:
            payload = json.loads((text or "").strip())
        except Exception as exc:
            raise GenerationError(
                error_code=GenerationErrorCode.INVALID_JSON,
                stage="smoke_validation",
                retryable=False,
                fallbackable=False,
                backend="generation_backend",
                details={"reason": "invalid_json"},
            ) from exc
        if payload != {"ok": True, "backend_smoke": "passed"}:
            raise GenerationError(
                error_code=GenerationErrorCode.SCHEMA_VALIDATION_FAILED,
                stage="smoke_validation",
                retryable=False,
                fallbackable=False,
                backend="generation_backend",
                details={"reason": "unexpected_smoke_payload"},
            )

    @classmethod
    def _text_smoke_validator(cls, text: str) -> None:
        if (text or "").strip() != "DSA_GENERATION_BACKEND_SMOKE_OK":
            raise GenerationError(
                error_code=GenerationErrorCode.SCHEMA_VALIDATION_FAILED,
                stage="smoke_validation",
                retryable=False,
                fallbackable=False,
                backend="generation_backend",
                details={"reason": "unexpected_smoke_text"},

View on GitHub (pinned to 5159bd72e8)

Solutions

  1. The smoke-validation response did not match the expected schema; verify the backend implements the expected API surface.
  2. Update the response schema/validator or fix the backend output so required fields are present with correct types.
  3. Confirm the configured model route matches the surface (e.g. openai/<model>) the validator expects.

When it happens

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

Common situations: Reported when the generation backend smoke validation response JSON does not match the expected schema; occurs when the upstream returns an error payload or an incompatible response shape.


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