Skip to content

Exit with error when QuiverQuant fetch returns no data#7

Merged
AlexCatarino merged 1 commit into
QuantConnect:masterfrom
AlexCatarino:bug-exit-on-empty-fetch
May 12, 2026
Merged

Exit with error when QuiverQuant fetch returns no data#7
AlexCatarino merged 1 commit into
QuantConnect:masterfrom
AlexCatarino:bug-exit-on-empty-fetch

Conversation

@AlexCatarino
Copy link
Copy Markdown
Member

@AlexCatarino AlexCatarino commented May 12, 2026

Summary

  • Detect QuiverQuant connection failures by treating an empty per-ticker accumulator at Flush() time as a hard failure (logs an error and returns false).
  • Wire Program.Main to propagate the Flush() result so the process exits with code 1 instead of silently succeeding when the API is unreachable.
  • Applies to the CNBC and InsiderTrading downloaders, whose multi-date loops previously logged per-date errors but always reported success overall.

Test plan

  • Run the CNBC downloader with a valid API key and confirm successful runs still exit 0 and write per-ticker files.
  • Run the CNBC downloader with the API unreachable (bad key / blocked host) and confirm the process exits 1 with the new Flush(): No data accumulated error.
  • Repeat both checks for the InsiderTrading downloader.

Treat an empty per-ticker accumulator at Flush time as a connection
failure: log an error and return false so Program.Main exits with
code 1 instead of producing a silent success when the API is
unreachable. Applies to CNBC and InsiderTrading downloaders, whose
multi-date loops previously swallowed per-date failures.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@AlexCatarino AlexCatarino merged commit 0db12b7 into QuantConnect:master May 12, 2026
1 check passed
@AlexCatarino AlexCatarino deleted the bug-exit-on-empty-fetch branch May 12, 2026 21:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant