cpython/Lib/test
Michael Droettboom c6127af868
gh-125063: Emit slices as constants in the bytecode compiler (#125064)
* Make slices marshallable

* Emit slices as constants

* Update Python/marshal.c

Co-authored-by: Peter Bierma <zintensitydev@gmail.com>

* Refactor codegen_slice into two functions so it
always has the same net effect

* Fix for free-threaded builds

* Simplify marshal loading of slices

* Only return SUCCESS/ERROR from codegen_slice

---------

Co-authored-by: Mark Shannon <mark@hotpy.org>
Co-authored-by: Peter Bierma <zintensitydev@gmail.com>
2024-10-08 13:18:39 -04:00
..
archivetestdata
audiodata
certdata gh-120762: make_ssl_certs: Don't set extensions for the temporary CSR (GH-125045) 2024-10-07 17:37:52 +02:00
cjkencodings
configdata
crashers
data
decimaltestdata Fix typos (#123775) 2024-09-09 14:58:26 +02:00
dtracedata
encoded_modules
leakers
libregrtest gh-124613, regrtest: Detect JIT in build info (#124793) 2024-09-30 20:50:41 +02:00
mathdata Fix typos (#123775) 2024-09-09 14:58:26 +02:00
regrtestdata/import_from_tests
subprocessdata
support gh-53203: Improve tests for strptime() (GH-125090) 2024-10-08 08:40:02 +00:00
test_ast gh-125010: Fix `use-after-free` in AST `repr()` (#125015) 2024-10-06 12:46:03 -07:00
test_asyncio GH-119866: Spill the stack around escaping calls. (GH-124392) 2024-10-07 14:56:39 +01:00
test_capi gh-124502: Add PyUnicode_Equal() function (#124504) 2024-10-07 21:24:53 +00:00
test_cext test_cext, test_cppext: enable /W4 warnings on Windows (#124253) 2024-09-19 22:32:01 +02:00
test_concurrent_futures Fix typos (#123775) 2024-09-09 14:58:26 +02:00
test_cppext test_cext, test_cppext: enable /W4 warnings on Windows (#124253) 2024-09-19 22:32:01 +02:00
test_ctypes gh-100980: ctypes: Test, document, and fix finalizing _fields_ (GH-124292) 2024-09-24 02:40:53 +02:00
test_dataclasses gh-118974: Add `decorator` argument to `make_dataclass` (gh-122723) 2024-10-01 09:51:51 -04:00
test_doctest gh-117482: Simplify the Fix For Builtin Types Slot Wrappers (GH-122865) 2024-09-09 16:04:58 +02:00
test_email
test_free_threading gh-124296: Remove private dictionary version tag (PEP 699) (#124472) 2024-10-01 12:39:56 -04:00
test_future_stmt
test_gdb
test_import gh-123880: Allow recursive import of single-phase-init modules (GH-123950) 2024-09-20 10:27:34 +02:00
test_importlib gh-123085: _compile_importlib: Avoid copying sources before compilation (GH-124131) 2024-09-18 14:14:34 +02:00
test_inspect gh-123339: Fix cases of inconsistency of __module__ and __firstlineno__ in classes (GH-123613) 2024-09-28 20:51:49 +03:00
test_interpreters
test_json
test_module
test_multiprocessing_fork
test_multiprocessing_forkserver
test_multiprocessing_spawn
test_pathlib
test_peg_generator
test_pydoc gh-113878: Add `doc` parameter to `dataclasses.field` (gh-114051) 2024-09-27 12:20:49 -04:00
test_pyrepl gh-125096: Don't import _pyrepl in site if PYTHON_BASIC_REPL (#125097) 2024-10-08 15:48:40 +02:00
test_sqlite3
test_tkinter
test_tomllib gh-124835: `tomllib.loads`: Raise TypeError not AttributeError. Improve message (#124587) 2024-10-01 19:58:08 -07:00
test_tools
test_ttk gh-86673: Harden `test_ttk.test_element_create_image` (#123335) 2024-09-27 08:21:15 +02:00
test_unittest gh-124176: Add special support for dataclasses to `create_autospec` (#124429) 2024-09-27 09:48:31 +03:00
test_warnings
test_zipfile Fix typos (#123775) 2024-09-09 14:58:26 +02:00
test_zoneinfo
tkinterdata
tokenizedata
tracedmodules
typinganndata
wheeldata
xmltestdata
zipimport_data
.ruff.toml
__init__.py
__main__.py
_test_atexit.py
_test_eintr.py
_test_embed_set_config.py
_test_embed_structseq.py gh-108303: Remove the non-test `Lib/test/reperf.py` (GH-114356) 2024-09-13 13:13:52 +02:00
_test_monitoring_shutdown.py
_test_multiprocessing.py gh-84559: Change the multiprocessing start method default to `forkserver` (GH-101556) 2024-09-26 16:57:19 -07:00
_test_venv_multiprocessing.py
archiver_tests.py
audiotests.py
audit-tests.py
autotest.py
bisect_cmd.py
clinic.test.c
cov.py
curses_tests.py
datetimetester.py gh-41431: Add `datetime.time.strptime()` and `datetime.date.strptime()` (#120752) 2024-09-25 14:43:58 -07:00
dis_module.py
empty.vbs
exception_hierarchy.txt
fork_wait.py
levenshtein_examples.json
list_tests.py
lock_tests.py
mapping_tests.py
memory_watchdog.py
mime.types
mock_socket.py
mp_fork_bomb.py
mp_preload.py
multibytecodec_support.py
pickletester.py gh-53203: Improve tests for strptime() (GH-125090) 2024-10-08 08:40:02 +00:00
profilee.py
pstats.pck
pyclbr_input.py
pythoninfo.py gh-123990: Good bye WITH_FREELISTS macro (gh-124358) 2024-09-24 01:28:59 +00:00
randv2_32.pck
randv2_64.pck
randv3.pck
re_tests.py
regrtest.py
relimport.py
seq_tests.py
signalinterproctester.py
ssl_servers.py
ssltests.py
string_tests.py closes gh-124016: update Unicode to 16.0.0 (#124017) 2024-09-13 07:47:04 -07:00
test___all__.py
test__colorize.py
test__interpchannels.py
test__interpreters.py gh-119180: No longer set `__annotations__` in `__main__` (#124634) 2024-09-27 05:49:43 -07:00
test__locale.py gh-69998: Fix decoding error in locale.nl_langinfo() (GH-124963) 2024-10-08 11:27:49 +03:00
test__opcode.py
test__osx_support.py
test_abc.py
test_abstract_numbers.py
test_android.py gh-116622: Mock the passage of time in Android logcat rate limit tests (#124015) 2024-09-13 04:58:11 +00:00
test_annotationlib.py gh-119180: Rename SOURCE format to STRING (#124620) 2024-09-26 13:49:48 -07:00
test_argparse.py gh-85935: Improve tests for invalid arguments in test_argparse (GH-124891) 2024-10-02 16:28:05 +03:00
test_array.py
test_asdl_parser.py
test_asyncgen.py
test_atexit.py
test_audit.py
test_augassign.py
test_base64.py
test_baseexception.py
test_bdb.py
test_bigaddrspace.py
test_bigmem.py
test_binascii.py
test_binop.py
test_bisect.py
test_bool.py
test_buffer.py
test_bufio.py
test_builtin.py gh-123339: Fix cases of inconsistency of __module__ and __firstlineno__ in classes (GH-123613) 2024-09-28 20:51:49 +03:00
test_bytes.py
test_bz2.py Bump Ruff to 0.6.7 (#124384) 2024-09-23 22:19:35 +00:00
test_c_locale_coercion.py
test_calendar.py gh-66436: Improved prog default value for argparse.ArgumentParser (GH-124799) 2024-10-01 22:51:40 +03:00
test_call.py
test_charmapcodec.py
test_class.py gh-124722: Fix leak in `test_detach_materialized_dict_no_memory` (GH-124769) 2024-09-29 20:47:45 -05:00
test_clinic.py
test_cmath.py gh-121039: add Floats/ComplexesAreIdenticalMixin to test.support.testcase (GH-121071) 2024-09-08 16:01:54 +03:00
test_cmd.py
test_cmd_line.py
test_cmd_line_script.py
test_code.py
test_code_module.py
test_codeccallbacks.py gh-124665: Add `_PyCodec_UnregisterError` and `_codecs._unregister_error` (#124677) 2024-09-29 02:25:23 +02:00
test_codecencodings_cn.py
test_codecencodings_hk.py
test_codecencodings_iso2022.py
test_codecencodings_jp.py
test_codecencodings_kr.py
test_codecencodings_tw.py
test_codecmaps_cn.py
test_codecmaps_hk.py
test_codecmaps_jp.py
test_codecmaps_kr.py
test_codecmaps_tw.py
test_codecs.py gh-53203: Improve tests for strptime() (GH-125090) 2024-10-08 08:40:02 +00:00
test_codeop.py
test_collections.py
test_colorsys.py
test_compare.py
test_compile.py gh-125063: Emit slices as constants in the bytecode compiler (#125064) 2024-10-08 13:18:39 -04:00
test_compileall.py
test_compiler_assemble.py
test_compiler_codegen.py gh-124188: Fix PyErr_ProgramTextObject() (GH-124189) 2024-09-24 11:01:37 +03:00
test_complex.py gh-121039: add Floats/ComplexesAreIdenticalMixin to test.support.testcase (GH-121071) 2024-09-08 16:01:54 +03:00
test_configparser.py
test_contains.py
test_context.py
test_contextlib.py Bump Ruff to 0.6.7 (#124384) 2024-09-23 22:19:35 +00:00
test_contextlib_async.py
test_copy.py
test_copyreg.py
test_coroutines.py
test_cprofile.py
test_csv.py gh-121982: ``csv``: Add a test case for invalid ``quoting`` constant. (#121983) 2024-10-03 11:14:57 +03:00
test_curses.py gh-120378: Fix crash caused by integer overflow in `curses` (#124555) 2024-10-02 14:31:23 +00:00
test_datetime.py
test_dbm.py
test_dbm_dumb.py
test_dbm_gnu.py
test_dbm_ndbm.py
test_dbm_sqlite3.py
test_decimal.py gh-53203: Improve tests for strptime() (GH-125090) 2024-10-08 08:40:02 +00:00
test_decorators.py
test_defaultdict.py
test_deque.py
test_descr.py
test_descrtut.py
test_devpoll.py
test_dict.py
test_dictcomps.py
test_dictviews.py
test_difflib.py
test_difflib_expect.html
test_dis.py Add "annotate" SET_FUNCTION_ATTRIBUTE bit to dis. (#124566) 2024-09-25 17:01:45 -07:00
test_docxmlrpc.py
test_dtrace.py
test_dynamic.py
test_dynamicclassattribute.py
test_eintr.py
test_embed.py bpo-34206: Improve docs and test coverage for pre-init functions (#8023) 2024-10-08 08:34:11 +00:00
test_ensurepip.py
test_enum.py Fix typos (#123775) 2024-09-09 14:58:26 +02:00
test_enumerate.py
test_eof.py gh-124188: Fix PyErr_ProgramTextObject() (GH-124189) 2024-09-24 11:01:37 +03:00
test_epoll.py
test_errno.py
test_except_star.py
test_exception_group.py
test_exception_hierarchy.py
test_exception_variations.py
test_exceptions.py gh-123378: fix a crash in `UnicodeError.__str__` (#124935) 2024-10-08 13:37:59 +02:00
test_extcall.py
test_external_inspection.py
test_faulthandler.py
test_fcntl.py
test_file.py
test_file_eintr.py
test_filecmp.py
test_fileinput.py
test_fileio.py
test_fileutils.py
test_finalization.py
test_float.py gh-53203: Improve tests for strptime() (GH-125090) 2024-10-08 08:40:02 +00:00
test_flufl.py
test_fnmatch.py
test_fork1.py
test_format.py
test_fractions.py Fix typos (#123775) 2024-09-09 14:58:26 +02:00
test_frame.py gh-124513: Check args in framelocalsproxy_new() (#124515) 2024-09-25 21:41:09 +02:00
test_frozen.py
test_fstring.py Fix typos (#123775) 2024-09-09 14:58:26 +02:00
test_ftplib.py
test_funcattrs.py gh-122864: Fix a ``test_funcattrs.test___builtins__`` when executing directly (#124845) 2024-10-02 12:58:39 +03:00
test_functools.py gh-119127: functools.partial placeholders (gh-119827) 2024-09-26 01:04:38 +00:00
test_gc.py gh-124538: Fix crash when using `gc.get_referents` on an untracked capsule object (#124559) 2024-09-26 12:29:43 +02:00
test_generated_cases.py GH-119866: Spill the stack around escaping calls. (GH-124392) 2024-10-07 14:56:39 +01:00
test_generator_stop.py
test_generators.py gh-123923: Defer refcounting for `f_executable` in `_PyInterpreterFrame` (#123924) 2024-09-12 12:37:06 -04:00
test_genericalias.py
test_genericclass.py
test_genericpath.py
test_genexps.py
test_getopt.py
test_getpass.py
test_getpath.py Fix typos (#123775) 2024-09-09 14:58:26 +02:00
test_gettext.py
test_glob.py
test_global.py
test_grammar.py
test_graphlib.py
test_grp.py
test_gzip.py
test_hash.py
test_hashlib.py
test_heapq.py
test_hmac.py
test_html.py
test_htmlparser.py
test_http_cookiejar.py
test_http_cookies.py
test_httplib.py
test_httpservers.py
test_idle.py
test_imaplib.py gh-53203: Improve tests for strptime() (GH-125090) 2024-10-08 08:40:02 +00:00
test_index.py
test_int.py
test_int_literal.py
test_io.py Bump Ruff to 0.6.7 (#124384) 2024-09-23 22:19:35 +00:00
test_ioctl.py
test_ipaddress.py gh-124217, ipaddress: Add RFC 9637 reserved IPv6 block `3fff::/20` (#124240) 2024-09-20 11:01:28 +00:00
test_isinstance.py
test_iter.py
test_iterlen.py
test_itertools.py gh-123884 Tee of tee was not producing n independent iterators (gh-124490) 2024-09-25 13:38:05 -07:00
test_keyword.py
test_keywordonlyarg.py
test_kqueue.py
test_largefile.py
test_launcher.py
test_linecache.py
test_list.py
test_listcomps.py
test_lltrace.py
test_locale.py GH-124108: Skip test_locale.test_strcoll_with_diacritic() on NetBSD (#124110) 2024-09-16 23:00:36 +00:00
test_logging.py gh-124653: Relax (again) detection of queue API for logging handlers (GH-124897) 2024-10-07 19:42:19 +01:00
test_long.py
test_longexp.py
test_lzma.py
test_mailbox.py
test_marshal.py
test_math.py gh-124040: Adjust few tests in testHypot/testDist to get exactly computed results (GH-124042) 2024-09-19 11:11:03 +03:00
test_math_property.py
test_memoryio.py
test_memoryview.py gh-77894: Fix a crash when the GC breaks a loop containing a memoryview (GH-123898) 2024-09-11 12:05:46 +03:00
test_metaclass.py
test_mimetypes.py
test_minidom.py
test_mmap.py gh-124213: Skip tests failing inside systemd-nspawn --suppress-sync=true (#124215) 2024-09-20 13:37:49 +00:00
test_modulefinder.py
test_monitoring.py GH-119866: Spill the stack around escaping calls. (GH-124392) 2024-10-07 14:56:39 +01:00
test_msvcrt.py Fix typos (#123775) 2024-09-09 14:58:26 +02:00
test_multibytecodec.py
test_multiprocessing_main_handling.py
test_named_expressions.py
test_netrc.py
test_ntpath.py
test_numeric_tower.py
test_opcache.py
test_opcodes.py
test_openpty.py
test_operator.py
test_optimizer.py
test_optparse.py
test_ordered_dict.py gh-119004: fix a crash in equality testing between `OrderedDict` (#121329) 2024-09-23 18:44:36 -05:00
test_os.py Bump Ruff to 0.6.7 (#124384) 2024-09-23 22:19:35 +00:00
test_osx_env.py
test_patma.py
test_pdb.py gh-124552 : Improve the accuracy of possible breakpoint check in bdb (#124553) 2024-10-04 21:32:57 -04:00
test_peepholer.py
test_pep646_syntax.py
test_perf_profiler.py gh-124613: Deactivate perf support in tests if the jit is set (#124794) 2024-10-04 02:00:32 +02:00
test_perfmaps.py
test_pickle.py
test_picklebuffer.py
test_pickletools.py
test_pkg.py
test_pkgutil.py gh-123780: Make test_pkgutil clean up `spam` module (GH-123036) 2024-09-06 15:23:55 +02:00
test_platform.py
test_plistlib.py
test_poll.py
test_popen.py
test_poplib.py
test_positional_only_arg.py
test_posix.py gh-123797: Check for runtime availability of `ptsname_r` on macos (#123806) 2024-09-20 09:30:27 +03:00
test_posixpath.py
test_pow.py
test_pprint.py
test_print.py
test_profile.py
test_property.py Fix typos (#123775) 2024-09-09 14:58:26 +02:00
test_pstats.py
test_pty.py
test_pulldom.py
test_pwd.py
test_py_compile.py
test_pyclbr.py
test_pyexpat.py
test_queue.py Fix typos (#123775) 2024-09-09 14:58:26 +02:00
test_quopri.py
test_raise.py
test_random.py gh-123968: Fix lower bound for `python -m random --float` (#123971) 2024-09-12 16:54:18 +03:00
test_range.py
test_re.py gh-124130: Increase test coverage for \b and \B in regular expressions (GH-124330) 2024-09-24 06:31:10 +00:00
test_readline.py gh-123321: Make Parser/myreadline.c locking safe in free-threaded build (#123690) 2024-09-06 15:07:08 -04:00
test_regrtest.py
test_repl.py gh-124594: Create and reuse the same context for the entire asyncio REPL session (#124595) 2024-10-01 14:17:22 +00:00
test_reprlib.py
test_resource.py
test_richcmp.py
test_rlcompleter.py
test_robotparser.py
test_runpy.py
test_sax.py
test_sched.py
test_scope.py
test_script_helper.py
test_secrets.py
test_select.py
test_selectors.py
test_set.py
test_setcomps.py
test_shelve.py
test_shlex.py
test_shutil.py gh-116622: Make test_unzip_zipfile recognize Android error message format (#124462) 2024-09-25 07:02:18 -07:00
test_signal.py gh-124083: Skip test_signal.test_strsignal() on NetBSD (#124084) 2024-09-18 21:22:00 +00:00
test_site.py
test_slice.py
test_smtplib.py
test_smtpnet.py
test_socket.py Fix typos (#123775) 2024-09-09 14:58:26 +02:00
test_socketserver.py
test_sort.py
test_source_encoding.py
test_ssl.py gh-119400: make_ssl_certs: update reference test data automatically, pass in expiration dates as parameters #119400 (GH-119401) 2024-09-25 21:23:47 +00:00
test_stable_abi_ctypes.py gh-124502: Add PyUnicode_Equal() function (#124504) 2024-10-07 21:24:53 +00:00
test_startfile.py
test_stat.py
test_statistics.py
test_str.py gh-53203: Improve tests for strptime() (GH-125090) 2024-10-08 08:40:02 +00:00
test_strftime.py
test_string.py
test_string_literals.py Fix typos (#123775) 2024-09-09 14:58:26 +02:00
test_stringprep.py
test_strptime.py gh-53203: Improve tests for strptime() (GH-125090) 2024-10-08 08:40:02 +00:00
test_strtod.py
test_struct.py gh-121249: Support _Complex types in the struct module (#121613) 2024-10-07 13:53:02 +02:00
test_structseq.py
test_subclassinit.py
test_subprocess.py
test_sundry.py
test_super.py gh-124402: Speed up test_free_threading and test_super (#124491) 2024-09-26 10:53:17 +02:00
test_support.py gh-124682: Disable test that is prone to intermittent failure on iOS. (#124683) 2024-09-27 10:49:35 -07:00
test_symtable.py
test_syntax.py
test_sys.py gh-123990: Good bye WITH_FREELISTS macro (gh-124358) 2024-09-24 01:28:59 +00:00
test_sys_setprofile.py
test_sys_settrace.py
test_sysconfig.py
test_syslog.py
test_tabnanny.py
test_tarfile.py
test_tcl.py
test_tempfile.py
test_termios.py gh-124030: Skip test_tcsendbreak on NetBSD for ENOTTY error (GH-124031) 2024-09-13 19:27:54 +03:00
test_textwrap.py
test_thread.py
test_threadedtempfile.py
test_threading.py gh-87135: Hang non-main threads that attempt to acquire the GIL during finalization (GH-105805) 2024-10-02 09:17:49 -07:00
test_threading_local.py
test_threadsignals.py
test_time.py gh-53203: Improve tests for strptime() (GH-125090) 2024-10-08 08:40:02 +00:00
test_timeit.py
test_timeout.py
test_tokenize.py gh-125008: Fix `tokenize.untokenize` roundtrip for `\n{{` (#125013) 2024-10-06 15:16:41 +02:00
test_trace.py
test_traceback.py gh-122145: Handle an empty AST body when reporting tracebacks (#122161) 2024-09-18 18:42:33 +02:00
test_tracemalloc.py
test_ttk_textonly.py
test_tty.py
test_tuple.py
test_turtle.py gh-123614: Add save function to turtle.py (#123617) 2024-09-12 21:36:17 -07:00
test_type_aliases.py gh-124498: Fix `TypeAliasType` not to be generic, when `type_params=()` (#124499) 2024-09-26 17:15:38 +03:00
test_type_annotations.py gh-119180: Rename SOURCE format to STRING (#124620) 2024-09-26 13:49:48 -07:00
test_type_cache.py
test_type_comments.py
test_type_params.py gh-119180: Rename SOURCE format to STRING (#124620) 2024-09-26 13:49:48 -07:00
test_typechecks.py
test_types.py gh-53203: Improve tests for strptime() (GH-125090) 2024-10-08 08:40:02 +00:00
test_typing.py gh-119180: Rename SOURCE format to STRING (#124620) 2024-09-26 13:49:48 -07:00
test_ucn.py
test_unary.py
test_unicode_file.py
test_unicode_file_functions.py
test_unicode_identifiers.py
test_unicodedata.py closes gh-124016: update Unicode to 16.0.0 (#124017) 2024-09-13 07:47:04 -07:00
test_univnewlines.py
test_unpack.py gh-122239: Add actual count in unbalanced unpacking error message when possible (#122244) 2024-09-10 16:07:30 +01:00
test_unpack_ex.py
test_unparse.py
test_urllib.py
test_urllib2.py
test_urllib2_localnet.py
test_urllib2net.py
test_urllib_response.py
test_urllibnet.py
test_urlparse.py
test_userdict.py
test_userlist.py
test_userstring.py
test_utf8_mode.py
test_utf8source.py
test_uuid.py
test_venv.py gh-124212: Fix undefined variable in error message in venv (GH-124211) 2024-09-18 22:05:18 +00:00
test_wait3.py
test_wait4.py
test_wave.py
test_weakref.py
test_weakset.py
test_webbrowser.py
test_winapi.py
test_winconsoleio.py
test_winreg.py
test_winsound.py
test_with.py Bump Ruff to 0.6.7 (#124384) 2024-09-23 22:19:35 +00:00
test_wmi.py
test_wsgiref.py
test_xml_dom_minicompat.py
test_xml_etree.py
test_xml_etree_c.py
test_xmlrpc.py
test_xxlimited.py
test_xxtestfuzz.py
test_yield_from.py
test_zipapp.py
test_zipfile64.py
test_zipimport.py Fix typos (#123775) 2024-09-09 14:58:26 +02:00
test_zipimport_support.py
test_zlib.py
testcodec.py
tf_inherit_check.py
win_console_handler.py
xmltests.py