cli icon indicating copy to clipboard operation
cli copied to clipboard

Fix test_lazy_choices_help failure on Python 3.14+

Open hroncok opened this issue 5 months ago • 2 comments

Python started raise early errors for invalid help strings, effectively triggering our LazyChoices action to query the options when added.

By using a custom ArgumentParser subclass that disables this check, LazyChoices works as intended.

Note that in real httpie code, all argument parsing is done via BaseHTTPieArgumentParser subclasses, so this fixes the problem in httpie as well as in the tests.

Directly using BaseHTTPieArgumentParser in test_lazy_choices_help is not trivial, as it would require more setup.

Fixes https://github.com/httpie/cli/issues/1641

hroncok avatar Jul 10 '25 22:07 hroncok

Python 3.7 CI is failing because that Python is no longer available.

hroncok avatar Jul 10 '25 22:07 hroncok

test_cli_utils.py seems to pass. All the other failures are unrelated.

hroncok avatar Jul 10 '25 22:07 hroncok