{"record":{"id":"7719fd6335a9f6ac","repo":"OpenBB-finance/OpenBB","slug":"no-data-was-returned-7719fd","errorCode":null,"errorMessage":"No data was returned.","messagePattern":"No data was returned\\.","errorType":"exception","errorClass":"EmptyDataError","httpStatus":null,"severity":"warning","filePath":"openbb_platform/providers/intrinio/openbb_intrinio/models/etf_info.py","lineNumber":641,"sourceCode":"            symbol + \":US\" if \":\" not in symbol else symbol for symbol in symbols\n        ]\n        urls = [f\"{base_url}{symbol}?api_key={api_key}\" for symbol in symbols]\n\n        results = []\n\n        async def response_callback(response, _):\n            \"\"\"Response callback.\"\"\"\n            result = await response.json()\n            if \"error\" in result:\n                warn(f\"Symbol Error: {result['error']} for {response.url.parts[-1]}\")\n                return\n            _ = result.pop(\"messages\", None)\n            results.append(result)\n\n        await amake_requests(urls, response_callback, **kwargs)  # type: ignore\n\n        if not results:\n            raise EmptyDataError(\"No data was returned.\")\n\n        return sorted(\n            results,\n            key=(lambda item: (symbols.index(item.get(\"figi_ticker\", len(symbols))))),\n        )\n\n    @staticmethod\n    def transform_data(\n        query: IntrinioEtfInfoQueryParams,\n        data: list[dict],\n        **kwargs: Any,\n    ) -> list[IntrinioEtfInfoData]:\n        \"\"\"Transform data.\"\"\"\n        return [IntrinioEtfInfoData.model_validate(d) for d in data]\n","sourceCodeStart":623,"sourceCodeEnd":656,"githubUrl":"https://github.com/OpenBB-finance/OpenBB/blob/3e071fcc2cd9f891cac6040ae60296dba76dab46/openbb_platform/providers/intrinio/openbb_intrinio/models/etf_info.py#L623-L656","documentation":"EmptyDataError raised in IntrinioEtfInfoFetcher after all per-symbol requests complete: each callback only warns ('Symbol Error: ... for <symbol>') on error responses and appends nothing, so if every symbol errored, 'results' stays empty and this error is raised.","triggerScenarios":"Calling etf.info / etf.search metadata with only invalid symbols; the warnings module output shows each individual failure reason (e.g. 'Symbol Error: ... for XYZ') while the final exception says only 'No data was returned.'.","commonSituations":"Bulk jobs where a stale ticker list contains symbols Intrinio doesn't recognize; warnings suppressed (python -W ignore or logging config) so users see only the opaque final error; one bad symbol among many still succeeds — only all-bad raises.","solutions":["Check captured warnings — they contain the per-symbol Intrinio error that explains the empty result","Validate/refresh the ticker list against obb.etf.search(provider='intrinio') before calling","Enable warnings display in production jobs (don't run with -W ignore) so the per-symbol cause is visible"],"exampleFix":"import warnings\nfrom openbb_core.provider.utils.errors import EmptyDataError\n\nwith warnings.catch_warnings(record=True) as w:\n    warnings.simplefilter(\"always\")\n    try:\n        res = obb.etf.info(provider=\"intrinio\", symbol=\"BAD1,BAD2\")\n    except EmptyDataError:\n        for warning in w:\n            print(warning.message)  # per-symbol Intrinio error text","handlingStrategy":"try-catch","validationCode":"def valid_etf_symbols(symbols: list[str], known: set[str]) -> list[str]:\n    \"\"\"Filter to symbols confirmed via etf.search to avoid all-error batches.\"\"\"\n    return [s for s in symbols if s.upper() in known]","typeGuard":"from openbb_core.provider.utils.errors import EmptyDataError","tryCatchPattern":"import warnings\nfrom openbb_core.provider.utils.errors import EmptyDataError\n\nwith warnings.catch_warnings(record=True) as caught:\n    warnings.simplefilter(\"always\")\n    try:\n        res = await obb.etf.info(provider=\"intrinio\", symbol=\",\".join(syms))\n    except EmptyDataError:\n        reasons = [str(w.message) for w in caught]  # per-symbol Intrinio errors\n        raise RuntimeError(f\"all symbols failed: {reasons}\") from None","preventionTips":["Record warnings around multi-symbol calls — individual failures only warn","Don't suppress warnings in jobs that rely on etf.info","Prefilter symbol lists through etf.search"],"tags":["etf","metadata","intrinio","empty-data","warnings"],"backgroundTag":null,"analyzedSha":"3e071fcc2cd9f891cac6040ae60296dba76dab46","analyzedAt":"2026-08-14T23:40:48.960Z","schemaVersion":2},"datasetVersion":"2026-08-15T17:31:12.345Z"}