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

CLI repeated query param handling #463

Merged
merged 6 commits into from May 10, 2021

Conversation

valgur
Copy link
Member

@valgur valgur commented May 8, 2021

Implements the suggestions 1. and 2. in #391:

  • Replaces comma-separated strings in --uuid, --name and --query with repeated application of that parameter.
  • Repeated query params get interpreted as an "or" expression.

valgur added 4 commits May 8, 2021 23:41
- Replace comma-separated lists with repeated CLI params.
- Repeated CLI query params get interpreted as an "or" expression.
@valgur valgur requested a review from j08lue May 8, 2021 21:16
@codecov
Copy link

codecov bot commented May 8, 2021

Codecov Report

Merging #463 (b2e41aa) into main (5a7f466) will increase coverage by 0.06%.
The diff coverage is 88.88%.

Impacted file tree graph

@@            Coverage Diff             @@
##             main     #463      +/-   ##
==========================================
+ Coverage   91.06%   91.12%   +0.06%     
==========================================
  Files           6        6              
  Lines         996     1003       +7     
  Branches      200      204       +4     
==========================================
+ Hits          907      914       +7     
  Misses         54       54              
  Partials       35       35              
Impacted Files Coverage Δ
sentinelsat/scripts/cli.py 92.80% <87.50%> (+0.26%) ⬆️
sentinelsat/sentinel.py 91.92% <100.00%> (+0.02%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 5a7f466...b2e41aa. Read the comment docs.

Copy link
Contributor

@j08lue j08lue left a comment

Choose a reason for hiding this comment

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

Nice addition with the key=value validation callback. 👍

Great improvement to reduce non-standard CLI behavior before we release v1. Thanks for picking this up!

…am-handling

# Conflicts:
#	CHANGELOG.rst
#	tests/fixtures/vcr_cassettes/test_name_search_multiple.yaml
#	tests/test_cli.py
@valgur valgur merged commit 45b8365 into sentinelsat:main May 10, 2021
@valgur valgur deleted the feature/cli-query-param-handling branch May 10, 2021 07:46
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.

None yet

2 participants