Data Download Future Options by Ticker

Open
#574 3 comments 1 reaction 0 assignees View on GitHub

Maintainers usually reply within 1 day

Nobody has claimed this yet.

Assessment

Difficulty
3/5
Estimated time
1-2 days
Newbie friendliness
35/100
Issue type
Bug
Clarity
Mostly clear
Activity status
Stale
Tech stack
python
Domain
cli, data

Research direction

Start by reproducing the two lean data download commands for US Future Options and US Future Option Universe. Inspect the LEAN CLI JSON path patterns and the database regex shown in the issue, then verify that expiry is handled for both downloads and that the commands locate the expected files.

Written by the indexing model from the issue text.

Description

bug feature

The following command doesn't download data:

$ lean data download --dataset "US Future Options" --data-type "trade" --ticker "ES" --market "cme" --resolution "minute" --start "20140101" --end "20250605"

Likely because of FutureOptions directory structure.

LEAN CLI json:

"all": [
                    "futureoption\/{market}\/{resolution}\/{ticker}"
                ]

I tested

"all": [
                    "futureoption\/{market}\/{resolution}\/{ticker}\/{expiry}\/{date}_{data-type}.zip"
                ]

by expiry would be required.

Regex in the database:

/^futureoption\/\w+\/minute\/\w+\/\w+\/[^\/]+\.zip$/m

By the way, LEAN CLI for US Future Option Universe:

$ lean data download --dataset "US Future Option Universe" --data-type "universe" --ticker "ES" --market "cme" --start "20240606" --end "20250606"

doesn't work (needs expiry).

Dominant language
Python
Stars
335
Forks
172
Avg merge
6h 54m
Merged PRs (30d)
37

Getting set up

This project ships no dev container, Dockerfile or contributing guide, so setting up is up to you: start from its README, and see our first-contribution guide for the general steps.

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from QuantConnect/lean-cli

All issues in QuantConnect/lean-cli

Similar issues

More Python issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.