]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
gh-116656: Fix test_capi test_py_config_isoloated_per_interpreter() (#116658)
authorVictor Stinner <vstinner@python.org>
Tue, 12 Mar 2024 17:31:35 +0000 (18:31 +0100)
committerGitHub <noreply@github.com>
Tue, 12 Mar 2024 17:31:35 +0000 (18:31 +0100)
Don't parse argv when setting the configuration, to avoid SystemExit if parsing argv fails.

Lib/test/test_capi/test_misc.py

index 64c0da6e3cc06ed0796390faf34e8925b544c341..c1395ab00077cb5f59325d98d270e2628c8ec42d 100644 (file)
@@ -1797,6 +1797,7 @@ class SubinterpreterTest(unittest.TestCase):
         # double checked at the time this test was written.
         config = _testinternalcapi.get_config()
         config['int_max_str_digits'] = 55555
+        config['parse_argv'] = 0
         _testinternalcapi.set_config(config)
         sub_value = _testinternalcapi.get_config()['int_max_str_digits']
         assert sub_value == 55555, sub_value