mirror of
https://github.com/OpenBB-finance/OpenBB.git
synced 2026-10-27 20:42:26 +00:00
* fix(sec): handle unexpected SEC API responses in cik_map and get_all_companies Fixes #7097 The cik_map command throws 'ValueError: If using all scalar values, you must pass an index' when the SEC API returns an unexpected response format (e.g., flat dict instead of nested dict of dicts). Changes: - get_all_companies: validate response before DataFrame creation, use from_dict(orient='index') instead of DataFrame().transpose(), check column count matches expected fields - cik_map fetcher: raise proper OpenBBError when symbol not found instead of returning empty dict that passes truthiness checks * run black --------- Co-authored-by: JasonOA888 <JasonOA888@users.noreply.github.com> Co-authored-by: Danglewood <85772166+deeleeramone@users.noreply.github.com>