#396 Add a --scenario argument to CLI
Merged by vmaljulin. Opened by vmaljulin.
vmaljulin/waiverdb RHELWF-1882  into  master

Download 396.patch

Why set scenario only for the last item?

Also, this should check if user is not passing both scenario and result-id - same as for the REST API.

rebased onto 512718df7125af4996034e60132a7e756ba76ad0

rebased onto 41bc9a47d2676d6411970af4350a7a66ffca65e4

Why set scenario only for the last item?

It was actually the last (and only) appended item. I've changed the code to be more clear.

Also, this should check if user is not passing both scenario and result-id - same as for the REST API.

Added

Why not just do 'scenario': scenario in the dict above? Wouldn't passing "scenario": null to the REST API work?

Can you instead add another example, something from real data? Here are results with scenario set: https://taskotron.fedoraproject.org/resultsdb_api/api/v2.0/results?scenario:like=*

rebased onto e5019525aa31cec662fe75beebe05af6f8193fbf

Updated

consider using dedent to have a cleaner indentation here.

This seems too long. PEP8 might fail. Could you move subject_identifier to the new line?

Just 2 tiny stylistic checks. Besides that it looks good +1
feel free to merge it once those are addressed.

Can you also update documentation under docs/? Looks like the examples are there listed too.

BTW, documenation is not auto-generated: https://docs.pagure.org/waiverdb/release-notes.html

For me, locally on Fedora 33, building documentation with tox -e docs also doesn't work - it's missing Python packages flask-migrate and stomp.py (dropping them into tox.ini fixes the issue).

This command should fail -- missing subject arguments.

rebased onto 8214f1a70eee178e15f6ded1425b4374ea46a4d7

rebased onto 910eddb9170d3ac70a37c5241f3c1aed7fee1a78

Updated

Add test for this.

Looks good except a missing test for the new exceptional case.

rebased onto c8e3cc4347e1e35e6900acfed1c6be489420ae70

Add test for this.

Added

Pull-Request has been merged by vmaljulin

Metadata