| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -470,6 +470,7 @@ Deprecated | |||
| 470 | 470 | * :c:func:`Py_GetPythonHome`: get :c:member:`PyConfig.home` or | |
| 471 | 471 | :envvar:`PYTHONHOME` environment variable instead. | |
| 472 | 472 | ||
| 473 | + Functions scheduled for removal in Python 3.15. | ||
| 473 | 474 | (Contributed by Victor Stinner in :gh:`105145`.) | |
| 474 | 475 | ||
| 475 | 476 | * Deprecate the :c:func:`PyImport_ImportModuleNoBlock` function which is just | |
@@ -612,3 +613,82 @@ Removed | |||
| 612 | 613 | <https://github.com/python/pythoncapi-compat/>`__ can be used to get | |
| 613 | 614 | :c:func:`PyInterpreterState_Get()` on Python 3.8 and older. | |
| 614 | 615 | (Contributed by Victor Stinner in :gh:`106320`.) | |
| 616 | + | ||
| 617 | + Pending Removal in Python 3.15 | ||
| 618 | + ------------------------------ | ||
| 619 | + | ||
| 620 | + * :c:func:`PyImport_ImportModuleNoBlock`: use :c:func:`PyImport_ImportModule`. | ||
| 621 | + * :c:func:`PyWeakref_GET_OBJECT`: use :c:func:`PyWeakref_GetRef` instead. | ||
| 622 | + * :c:func:`PyWeakref_GetObject`: use :c:func:`PyWeakref_GetRef` instead. | ||
| 623 | + * :c:type:`!Py_UNICODE_WIDE` type: use ``wchar_t`` instead. | ||
| 624 | + * :c:type:`Py_UNICODE` type: use ``wchar_t`` instead. | ||
| 625 | + * Python initialization functions: | ||
| 626 | + | ||
| 627 | + * :c:func:`PySys_ResetWarnOptions`: clear :data:`sys.warnoptions` and | ||
| 628 | + :data:`!warnings.filters` instead. | ||
| 629 | + * :c:func:`Py_GetExecPrefix`: get :data:`sys.exec_prefix` instead. | ||
| 630 | + * :c:func:`Py_GetPath`: get :data:`sys.path` instead. | ||
| 631 | + * :c:func:`Py_GetPrefix`: get :data:`sys.prefix` instead. | ||
| 632 | + * :c:func:`Py_GetProgramFullPath`: get :data:`sys.executable` instead. | ||
| 633 | + * :c:func:`Py_GetProgramName`: get :data:`sys.executable` instead. | ||
| 634 | + * :c:func:`Py_GetPythonHome`: get :c:member:`PyConfig.home` or | ||
| 635 | + :envvar:`PYTHONHOME` environment variable instead. | ||
| 636 | + | ||
| 637 | + Pending Removal in Future Versions | ||
| 638 | + ---------------------------------- | ||
| 639 | + | ||
| 640 | + The following APIs were deprecated in earlier Python versions and will be | ||
| 641 | + removed, although there is currently no date scheduled for their removal. | ||
| 642 | + | ||
| 643 | + * :const:`Py_TPFLAGS_HAVE_FINALIZE`: no needed since Python 3.8. | ||
| 644 | + * :c:func:`PyErr_Fetch`: use :c:func:`PyErr_GetRaisedException`. | ||
| 645 | + * :c:func:`PyErr_NormalizeException`: use :c:func:`PyErr_GetRaisedException`. | ||
| 646 | + * :c:func:`PyErr_Restore`: use :c:func:`PyErr_SetRaisedException`. | ||
| 647 | + * :c:func:`PyModule_GetFilename`: use :c:func:`PyModule_GetFilenameObject`. | ||
| 648 | + * :c:func:`PyOS_AfterFork`: use :c:func:`PyOS_AfterFork_Child()`. | ||
| 649 | + * :c:func:`PySlice_GetIndicesEx`. | ||
| 650 | + * :c:func:`!PyUnicode_AsDecodedObject`. | ||
| 651 | + * :c:func:`!PyUnicode_AsDecodedUnicode`. | ||
| 652 | + * :c:func:`!PyUnicode_AsEncodedObject`. | ||
| 653 | + * :c:func:`!PyUnicode_AsEncodedUnicode`. | ||
| 654 | + * :c:func:`PyUnicode_READY`: not needed since Python 3.12. | ||
| 655 | + * :c:func:`!_PyErr_ChainExceptions`. | ||
| 656 | + * :c:member:`!PyBytesObject.ob_shash` member: | ||
| 657 | + call :c:func:`PyObject_Hash` instead. | ||
| 658 | + * :c:member:`!PyDictObject.ma_version_tag` member. | ||
| 659 | + * Global configuration variables: | ||
| 660 | + | ||
| 661 | + * :c:var:`Py_DebugFlag`: use :c:member:`PyConfig.parser_debug` | ||
| 662 | + * :c:var:`Py_VerboseFlag`: use :c:member:`PyConfig.verbose` | ||
| 663 | + * :c:var:`Py_QuietFlag`: use :c:member:`PyConfig.quiet` | ||
| 664 | + * :c:var:`Py_InteractiveFlag`: use :c:member:`PyConfig.interactive` | ||
| 665 | + * :c:var:`Py_InspectFlag`: use :c:member:`PyConfig.inspect` | ||
| 666 | + * :c:var:`Py_OptimizeFlag`: use :c:member:`PyConfig.optimization_level` | ||
| 667 | + * :c:var:`Py_NoSiteFlag`: use :c:member:`PyConfig.site_import` | ||
| 668 | + * :c:var:`Py_BytesWarningFlag`: use :c:member:`PyConfig.bytes_warning` | ||
| 669 | + * :c:var:`Py_FrozenFlag`: use :c:member:`PyConfig.pathconfig_warnings` | ||
| 670 | + * :c:var:`Py_IgnoreEnvironmentFlag`: use :c:member:`PyConfig.use_environment` | ||
| 671 | + * :c:var:`Py_DontWriteBytecodeFlag`: use :c:member:`PyConfig.write_bytecode` | ||
| 672 | + * :c:var:`Py_NoUserSiteDirectory`: use :c:member:`PyConfig.user_site_directory` | ||
| 673 | + * :c:var:`Py_UnbufferedStdioFlag`: use :c:member:`PyConfig.buffered_stdio` | ||
| 674 | + * :c:var:`Py_HashRandomizationFlag`: use :c:member:`PyConfig.use_hash_seed` | ||
| 675 | + and :c:member:`PyConfig.hash_seed` | ||
| 676 | + * :c:var:`Py_IsolatedFlag`: use :c:member:`PyConfig.isolated` | ||
| 677 | + * :c:var:`Py_LegacyWindowsFSEncodingFlag`: use :c:member:`PyPreConfig.legacy_windows_fs_encoding` | ||
| 678 | + * :c:var:`Py_LegacyWindowsStdioFlag`: use :c:member:`PyConfig.legacy_windows_stdio` | ||
| 679 | + * :c:var:`!Py_FileSystemDefaultEncoding`: use :c:member:`PyConfig.filesystem_encoding` | ||
| 680 | + * :c:var:`!Py_HasFileSystemDefaultEncoding`: use :c:member:`PyConfig.filesystem_encoding` | ||
| 681 | + * :c:var:`!Py_FileSystemDefaultEncodeErrors`: use :c:member:`PyConfig.filesystem_errors` | ||
| 682 | + * :c:var:`!Py_UTF8Mode`: use :c:member:`PyPreConfig.utf8_mode` (see :c:func:`Py_PreInitialize`) | ||
| 683 | + | ||
| 684 | + The :c:func:`Py_InitializeFromConfig` API should be used with | ||
| 685 | + :c:type:`PyConfig` instead. | ||
| 686 | + | ||
| 687 | + * TLS API: | ||
| 688 | + | ||
| 689 | + * :c:func:`PyThread_create_key`: use :c:func:`PyThread_tss_alloc`. | ||
| 690 | + * :c:func:`PyThread_delete_key`: use :c:func:`PyThread_tss_free`. | ||
| 691 | + * :c:func:`PyThread_set_key_value`: use :c:func:`PyThread_tss_set`. | ||
| 692 | + * :c:func:`PyThread_get_key_value`: use :c:func:`PyThread_tss_get`. | ||
| 693 | + * :c:func:`PyThread_delete_key_value`: use :c:func:`PyThread_tss_delete`. | ||
| 694 | + * :c:func:`PyThread_ReInitTLS`: no longer needed. | ||
| Back | FazBrowse Home | New Git URL |
0 commit comments