TradingAgents/tests
ahmet guzererler 6fa4c2340a
Fix `ThirdPartyTimeoutError` swallowing in `yfinance` dataflows (#127)
In dataflow API wrappers, generic `except Exception` handlers were swallowing
timeout exceptions (like `requests.exceptions.Timeout` and `ThirdPartyTimeoutError`),
preventing upstream retry logic and proper error handling from functioning correctly.

This patch:
- Adds explicit catching of `requests.exceptions.Timeout` to raise as `ThirdPartyTimeoutError` in `yfinance` wrapper modules (`y_finance.py`, `yfinance_news.py`, `yfinance_scanner.py`).
- Adds explicit catching and re-raising of `ThirdPartyTimeoutError` before generic exception handlers across the dataflows.
- Retains existing exception inheritance logic to avoid backward compatibility breaks.
- Updates `TestEnsureIndexesInInit` to use the explicit `ensure_indexes()` call per lazy loading changes.

Co-authored-by: google-labs-jules[bot] <161369871+google-labs-jules[bot]@users.noreply.github.com>
Co-authored-by: aguzererler <6199053+aguzererler@users.noreply.github.com>
2026-03-27 00:20:10 +01:00
..
cassettes Add integration and unit tests for scanner routing, TTM analysis, vendor fail-fast, and yfinance data layer 2026-03-19 13:51:57 +01:00
cli fix: update test_stats_handler.py for langchain_core >=1.0 compatibility 2026-03-22 06:58:38 +00:00
e2e refactor(tests): consolidate live-API tests into integration/, move mocked tests to unit/ 2026-03-19 14:24:52 +01:00
integration feat: add launch configuration for FastAPI and Vite; enhance Finviz filter validation tests (#110) 2026-03-25 15:50:49 +01:00
portfolio feat: Add macro scanner feedback loop and lessons memory (#124) 2026-03-26 23:44:44 +01:00
unit Fix `ThirdPartyTimeoutError` swallowing in `yfinance` dataflows (#127) 2026-03-27 00:20:10 +01:00
__init__.py Initial plan for portfolio manager phases 2-5 2026-03-20 14:27:37 +00:00
conftest.py fix(tests): complete PR #26 — enforce socket isolation in unit tier and add test suite reference doc (#30) 2026-03-19 17:41:25 +01:00
test_ticker_symbol_handling.py fix: preserve exchange-qualified tickers across agent prompts 2026-03-21 21:10:13 +08:00