Skip to content

Commit

Permalink
Minor fix for QC data download
Browse files Browse the repository at this point in the history
  • Loading branch information
Martin-Molinero committed May 2, 2024
1 parent a20b2f4 commit 8ed68ae
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
3 changes: 2 additions & 1 deletion lean/commands/data/download.py
Original file line number Diff line number Diff line change
Expand Up @@ -352,7 +352,8 @@ def _select_products_non_interactive(organization: QCFullOrganization,
if option.condition is not None and not option.condition.check(option_results):
continue

user_input = ctx.params.get(option.id, None)
# if the option id has a '-' in its name, and it's a click option, in the click context it's available with '_'
user_input = ctx.params.get(option.id.replace('-', '_'), ctx.params.get(option.id, None))

if user_input is None:
missing_options.append(f"--{option.id} <{option.get_placeholder()}>: {option.description}")
Expand Down
1 change: 1 addition & 0 deletions lean/models/api.py
Original file line number Diff line number Diff line change
Expand Up @@ -410,6 +410,7 @@ class QCMinimalOrganization(WrappedBaseModel):
class QCDataType(str, Enum):
Trade = "Trade"
Quote = "Quote"
Bulk = "Bulk"
OpenInterest = "OpenInterest"

@classmethod
Expand Down

0 comments on commit 8ed68ae

Please sign in to comment.