Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix parsing of command line parameter overrides using whitespace #38

Merged
merged 2 commits into from
Sep 29, 2022

Conversation

qikaigu
Copy link
Contributor

@qikaigu qikaigu commented Sep 28, 2022

Close #37

paths, overrides, command = parse_args()
expected_paths = ["config.yaml"]
expected_overrides = {"output": "/tmp"}
expected_command = "run"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe it could be worth adding a unit test that covers the case of first example in the doc (https://fromconfig.github.io/#/). In such a case there are two "-".
I don't see why your code would not work in such setting but it is probably worth being sure that doc won't break.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good idea! The test case is added by the commit below.

@qikaigu qikaigu requested a review from Mbompr September 29, 2022 11:39
@Mbompr Mbompr merged commit 2d8d86b into criteo:main Sep 29, 2022
@qikaigu qikaigu deleted the fix-args-parsing branch September 29, 2022 17:21
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.

Command line parameter overrides incorrectly parsed
2 participants