14 Commits

Author SHA1 Message Date
Gerardo Salazar 82c9b6ccb7 Updates and improvements to ToolBox projects (#5537)
Build & Test Lean / build (push) Has been cancelled
* Adds processed data directory to read price data from

* Make coarse universe generator look at data directory before failing to find daily data

* Set coarse generator output of missing daily file to debug log

* Add CoarseUniverseGenerator logs

* Fixes 100 nanosecond increment lookahead bias when parsing large numbers

  * Whenever we parse a number that is has precision greater than
    DateTime ticks (sub-100 nanoseconds), if we have nanoseconds
    between [0, 1000), excluding numbers divisible by 100,
    we will have leftover nanoseconds between [0, 100) nanoseconds, but
    they won't be factored in to the DateTime calculation, since casting
    to `long` only takes the integer component of the number, so we lose
    the extra nanoseconds that came with the decimal, and time is set to
    the "floored" value without those nanoseconds.

    Since .NET `DateTime` type has a limitation of only being able
    to represent time in increments of 100 nanoseconds, by not
    considering the sub-100 nanoseconds, we introduce a look-ahead
    bias of at most 100 nanoseconds/1 tick

  * Misc adjustment to make method use `decimal` instead of `double`
    for increased precision when parsing large numbers

* Changes CoinAPI data converter to support processing raw files in original directory structure and file name

  * Removes Market requirement from CoinAPI data converter

* Remove timeout on decompression of raw AlgoSeek futures data

* Updates SEC downloader to use HttpClient where requests were failing

  * For some unknown reason, valid requests to a valid URL were
    failing when using WebClient. Changing our requester to
    HttpClient fixes the issue, and enables us to leverage
    async capabilities where applicable.

  * Added fault tolerance to index file downloads, including a
    rate limit in case we've been rate limited

* Further refactoring; catches 429 errors, adds missing rategate calls

* Replace all usage of WebClient, force retry for all failures

* Adds optional config value for Benzinga News API key in downloader

* Modifies Estimize Downloader api config name and fixes directory not found bug

* Refactor Estimize to speed up processing time

  * Adds ticker limits if desired
  * Misc. bug fixes, performance improvements, code cleanup

* Remove debug log statements leftover from previous commit

* Add support for non-tick Index resolutions in LeanDataWriter

* Empty commit

* Empty commit

* Empty commit

* Empty commit

* Empty commit

* Empty commit

* Lower requests/second for SEC downloader, add missing rategate call

Co-authored-by: Martin-Molinero <martin@quantconnect.com>
2021-05-14 17:06:47 -03:00
Gerardo Salazar 7036a3e99c Address review - add missing continue statement and extends unit tests 2020-05-11 15:14:43 -07:00
Gerardo Salazar 4a923e3e43 Address review - add tests and reduce code duplication
* Refactors the delimiter detection method to make adding new
    values quick and easy.
2020-05-11 13:46:08 -07:00
Gerardo Salazar 5d6c5c6235 Fix processing issue that stopped Estimize from completing successfully
* We made an assumption that all tickers marked as "defunct" from
    Estimize would have a dash '-' separating the defunct indicator
    from the ticker. However, there was a ticker where the defunct
    separator was actually an underscore '_'. There are now
    additional checks in place to ensure that we do not pass the
    Substring method an invalid 'length' value.
2020-05-11 12:22:06 -07:00
Martin-Molinero 1d9d10c2e9 Merge pull request #4219 from gsalaz98/bug-fix-estimize-converter-share-class-tickers-skipped
Fixes bug where share class tickers (e.g. BRK.B) would not be processed for Estimize
2020-03-18 19:48:31 -03:00
Gerardo Salazar cba9ae2e9e Fixes bug where share class tickers (BRK.B) would not be downloaded and converted
* Removes try/catch around RateGate, since it was fixed in issue #3499
2020-03-18 15:07:30 -07:00
Stefano Raggi 70f90afce0 Fix Estimize time zone bug in timestamp deserialization 2020-03-14 00:30:10 +01:00
Michael Handschuh d21d620457 Update ToolBox to respect CA1304 and CA1305
Updates all occurrences of parsing/ToString-ing to go through the new
StringExtensions methods that use CultureInfo.InvariantCulture

See #3045
2019-09-12 15:30:45 -04:00
Gerardo Salazar c5d3d050b4 Add error handling for potential RateGate failure 2019-07-30 14:29:44 -07:00
Gerardo Salazar 0fb996acc1 Update Estimize data to include seconds
Fix bug where we would call SaveContentToFile more than once
2019-07-29 10:07:42 -07:00
Gerardo Salazar 11879119c1 Make downloaders use map files for historical ticker resolution
Fix issue in Consensus downloader where attempt to select non-duplicates would cause a chunk
of data to be dropped and never processed

Update output path to be CSV files instead of JSON, non-zipped

Fix documentation

Fix bug where we would not properly output files
2019-07-26 17:32:47 -07:00
Gerardo Salazar b1434bfef4 Add completion tracking in Estimize downloaders (excluding consensus)
Add better logging to estimize downloaders

Speed up estimize consensus downloader by checking for duplicates

Move duplicated code to single method
2019-07-18 17:03:23 -07:00
AlexCatarino bb5cec3a49 Address Review and Fix Unit Tests 2019-06-21 13:14:47 +01:00
AlexCatarino 7b81f1a64d Implements Estimize Equity Endpoints Alternative Data
- Release: Financial releases for the specified company
- Estimate: Financial estimates for the specified company
- Consensus: Consensus of the specified release

For each equity endpoint, we create a `BaseData`, a Downloader and add unit tests.
2019-06-21 13:14:47 +01:00