Commit 03f5f52
committed
fix: handle GraphQL errors in security_id_to_symbol gracefully
Some securities (e.g., delisted, private, or certain ETFs) fail when
the FetchSecurityMarketData GraphQL query returns UNPROCESSABLE_ENTITY.
This change wraps the get_security_market_data call in a try/except
block to catch WSApiException and gracefully fall back to returning
the bracketed security ID instead of crashing.1 parent 653dd49 commit 03f5f52
1 file changed
Lines changed: 8 additions & 4 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
713 | 713 | | |
714 | 714 | | |
715 | 715 | | |
716 | | - | |
717 | | - | |
718 | | - | |
719 | | - | |
| 716 | + | |
| 717 | + | |
| 718 | + | |
| 719 | + | |
| 720 | + | |
| 721 | + | |
| 722 | + | |
| 723 | + | |
720 | 724 | | |
721 | 725 | | |
722 | 726 | | |
| |||
0 commit comments