You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Over on typing-extensions we run the typed-argument-parser tests daily on various Python versions. They started failing on Python 3.13 (python/typing_extensions#513):
https://github.com/python/typing_extensions/actions/runs/12172317648/job/33950775320
typed-argument-parser tests are failing on 3.13:
=========================== short test summary info ============================
FAILED tests/test_to_tap_class.py::test_subclasser_subparser[function-args_string_and_arg_to_expected_value7] - assert "error: argument {a,b}: invalid choice: 'X' (choose from 'a', 'b')" in "usage: pytest [--foo] --arg_int ARG_INT [--arg_bool]\n [--arg_list [ARG_LIST ...]] [-h]\n {a,b} ...\npytest: error: argument {a,b}: invalid choice: 'X' (choose from a, b)\n"
+ where "error: argument {a,b}: invalid choice: 'X' (choose from 'a', 'b')" = str(SystemExit("error: argument {a,b}: invalid choice: 'X' (choose from 'a', 'b')"))
FAILED tests/test_to_tap_class.py::test_subclasser_subparser[Class-args_string_and_arg_to_expected_value7] - assert "error: argument {a,b}: invalid choice: 'X' (choose from 'a', 'b')" in "usage: pytest [--foo] --arg_int ARG_INT [--arg_bool]\n [--arg_list [ARG_LIST ...]] [-h]\n {a,b} ...\npytest: error: argument {a,b}: invalid choice: 'X' (choose from a, b)\n"
+ where "error: argument {a,b}: invalid choice: 'X' (choose from 'a', 'b')" = str(SystemExit("error: argument {a,b}: invalid choice: 'X' (choose from 'a', 'b')"))
FAILED tests/test_to_tap_class.py::test_subclasser_subparser[_Args-args_string_and_arg_to_expected_value7] - assert "error: argument {a,b}: invalid choice: 'X' (choose from 'a', 'b')" in "usage: pytest [--foo] --arg_int ARG_INT [--arg_bool]\n [--arg_list [ARG_LIST ...]] [-h]\n {a,b} ...\npytest: error: argument {a,b}: invalid choice: 'X' (choose from a, b)\n"
+ where "error: argument {a,b}: invalid choice: 'X' (choose from 'a', 'b')" = str(SystemExit("error: argument {a,b}: invalid choice: 'X' (choose from 'a', 'b')"))
FAILED tests/test_to_tap_class.py::test_subclasser_subparser[class_or_function_3-args_string_and_arg_to_expected_value7] - assert "error: argument {a,b}: invalid choice: 'X' (choose from 'a', 'b')" in "usage: pytest [--foo] --arg_int ARG_INT [--arg_bool]\n [--arg_list [ARG_LIST ...]] [-h]\n {a,b} ...\npytest: error: argument {a,b}: invalid choice: 'X' (choose from a, b)\n"
+ where "error: argument {a,b}: invalid choice: 'X' (choose from 'a', 'b')" = str(SystemExit("error: argument {a,b}: invalid choice: 'X' (choose from 'a', 'b')"))
======================== 4 failed, 301 passed in 1.58s =========================
I suspect it's related to some of the argparse changes in Python 3.13.1. (Run git diff v3.13.0 v3.13.1 -- Lib/argparse.py in the CPython repo; a fair amount of code changed.) I haven't looked into this further.
The text was updated successfully, but these errors were encountered:
This is likely a consequence of python/cpython#117766, which changed how the choices are displayed in the error message (switched from repr to str). That PR was backported to 3.13.1 and 3.12.8
Thank you @JelleZijlstra for raising this issue! We're happy to hear that Tap is being tested more broadly! We've accepted @brianschubert's fix, which seems to solve the string match problem for the error message.
Over on typing-extensions we run the typed-argument-parser tests daily on various Python versions. They started failing on Python 3.13 (python/typing_extensions#513):
https://github.com/python/typing_extensions/actions/runs/12172317648/job/33950775320
I suspect it's related to some of the argparse changes in Python 3.13.1. (Run
git diff v3.13.0 v3.13.1 -- Lib/argparse.py
in the CPython repo; a fair amount of code changed.) I haven't looked into this further.The text was updated successfully, but these errors were encountered: