Skip to content

Commit 7a468a1

Browse files
StanFromIrelandsavannahostrowskiJelleZijlstrabrettcannon
authored
gh-150032: Tidy up 3.15 pending removals (#149594)
Co-authored-by: Savannah Ostrowski <savannah@python.org> Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com> Co-authored-by: Brett Cannon <brett@python.org>
1 parent b643826 commit 7a468a1

9 files changed

Lines changed: 117 additions & 118 deletions

Doc/c-api/interp-lifecycle.rst

Lines changed: 21 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -104,7 +104,7 @@ to 1 and ``-bb`` sets :c:data:`Py_BytesWarningFlag` to 2.
104104

105105
Set by the :option:`-b` option.
106106

107-
.. deprecated-removed:: 3.12 3.15
107+
.. deprecated-removed:: 3.12 3.16
108108

109109

110110
.. c:var:: int Py_DebugFlag
@@ -119,7 +119,7 @@ to 1 and ``-bb`` sets :c:data:`Py_BytesWarningFlag` to 2.
119119
Set by the :option:`-d` option and the :envvar:`PYTHONDEBUG` environment
120120
variable.
121121

122-
.. deprecated-removed:: 3.12 3.15
122+
.. deprecated-removed:: 3.12 3.16
123123

124124

125125
.. c:var:: int Py_DontWriteBytecodeFlag
@@ -134,7 +134,7 @@ to 1 and ``-bb`` sets :c:data:`Py_BytesWarningFlag` to 2.
134134
Set by the :option:`-B` option and the :envvar:`PYTHONDONTWRITEBYTECODE`
135135
environment variable.
136136

137-
.. deprecated-removed:: 3.12 3.15
137+
.. deprecated-removed:: 3.12 3.16
138138

139139

140140
.. c:var:: int Py_FrozenFlag
@@ -145,7 +145,7 @@ to 1 and ``-bb`` sets :c:data:`Py_BytesWarningFlag` to 2.
145145

146146
Private flag used by ``_freeze_module`` and ``frozenmain`` programs.
147147

148-
.. deprecated-removed:: 3.12 3.15
148+
.. deprecated-removed:: 3.12 3.16
149149

150150

151151
.. c:var:: int Py_HashRandomizationFlag
@@ -161,7 +161,7 @@ to 1 and ``-bb`` sets :c:data:`Py_BytesWarningFlag` to 2.
161161
If the flag is non-zero, read the :envvar:`PYTHONHASHSEED` environment
162162
variable to initialize the secret hash seed.
163163

164-
.. deprecated-removed:: 3.12 3.15
164+
.. deprecated-removed:: 3.12 3.16
165165

166166

167167
.. c:var:: int Py_IgnoreEnvironmentFlag
@@ -175,7 +175,7 @@ to 1 and ``-bb`` sets :c:data:`Py_BytesWarningFlag` to 2.
175175

176176
Set by the :option:`-E` and :option:`-I` options.
177177

178-
.. deprecated-removed:: 3.12 3.15
178+
.. deprecated-removed:: 3.12 3.16
179179

180180

181181
.. c:var:: int Py_InspectFlag
@@ -191,7 +191,7 @@ to 1 and ``-bb`` sets :c:data:`Py_BytesWarningFlag` to 2.
191191
Set by the :option:`-i` option and the :envvar:`PYTHONINSPECT` environment
192192
variable.
193193

194-
.. deprecated-removed:: 3.12 3.15
194+
.. deprecated-removed:: 3.12 3.16
195195

196196

197197
.. c:var:: int Py_InteractiveFlag
@@ -202,7 +202,7 @@ to 1 and ``-bb`` sets :c:data:`Py_BytesWarningFlag` to 2.
202202

203203
Set by the :option:`-i` option.
204204

205-
.. deprecated-removed:: 3.12 3.15
205+
.. deprecated-removed:: 3.12 3.16
206206

207207

208208
.. c:var:: int Py_IsolatedFlag
@@ -218,7 +218,7 @@ to 1 and ``-bb`` sets :c:data:`Py_BytesWarningFlag` to 2.
218218

219219
.. versionadded:: 3.4
220220

221-
.. deprecated-removed:: 3.12 3.15
221+
.. deprecated-removed:: 3.12 3.16
222222

223223

224224
.. c:var:: int Py_LegacyWindowsFSEncodingFlag
@@ -238,7 +238,7 @@ to 1 and ``-bb`` sets :c:data:`Py_BytesWarningFlag` to 2.
238238

239239
.. availability:: Windows.
240240

241-
.. deprecated-removed:: 3.12 3.15
241+
.. deprecated-removed:: 3.12 3.16
242242

243243

244244
.. c:var:: int Py_LegacyWindowsStdioFlag
@@ -257,7 +257,7 @@ to 1 and ``-bb`` sets :c:data:`Py_BytesWarningFlag` to 2.
257257

258258
.. availability:: Windows.
259259

260-
.. deprecated-removed:: 3.12 3.15
260+
.. deprecated-removed:: 3.12 3.16
261261

262262

263263
.. c:var:: int Py_NoSiteFlag
@@ -273,7 +273,7 @@ to 1 and ``-bb`` sets :c:data:`Py_BytesWarningFlag` to 2.
273273

274274
Set by the :option:`-S` option.
275275

276-
.. deprecated-removed:: 3.12 3.15
276+
.. deprecated-removed:: 3.12 3.16
277277

278278

279279
.. c:var:: int Py_NoUserSiteDirectory
@@ -288,7 +288,7 @@ to 1 and ``-bb`` sets :c:data:`Py_BytesWarningFlag` to 2.
288288
Set by the :option:`-s` and :option:`-I` options, and the
289289
:envvar:`PYTHONNOUSERSITE` environment variable.
290290

291-
.. deprecated-removed:: 3.12 3.15
291+
.. deprecated-removed:: 3.12 3.16
292292

293293

294294
.. c:var:: int Py_OptimizeFlag
@@ -300,7 +300,7 @@ to 1 and ``-bb`` sets :c:data:`Py_BytesWarningFlag` to 2.
300300
Set by the :option:`-O` option and the :envvar:`PYTHONOPTIMIZE` environment
301301
variable.
302302

303-
.. deprecated-removed:: 3.12 3.15
303+
.. deprecated-removed:: 3.12 3.16
304304

305305

306306
.. c:var:: int Py_QuietFlag
@@ -315,7 +315,7 @@ to 1 and ``-bb`` sets :c:data:`Py_BytesWarningFlag` to 2.
315315

316316
.. versionadded:: 3.2
317317

318-
.. deprecated-removed:: 3.12 3.15
318+
.. deprecated-removed:: 3.12 3.16
319319

320320

321321
.. c:var:: int Py_UnbufferedStdioFlag
@@ -329,7 +329,7 @@ to 1 and ``-bb`` sets :c:data:`Py_BytesWarningFlag` to 2.
329329
Set by the :option:`-u` option and the :envvar:`PYTHONUNBUFFERED`
330330
environment variable.
331331

332-
.. deprecated-removed:: 3.12 3.15
332+
.. deprecated-removed:: 3.12 3.16
333333

334334

335335
.. c:var:: int Py_VerboseFlag
@@ -346,7 +346,7 @@ to 1 and ``-bb`` sets :c:data:`Py_BytesWarningFlag` to 2.
346346
Set by the :option:`-v` option and the :envvar:`PYTHONVERBOSE` environment
347347
variable.
348348

349-
.. deprecated-removed:: 3.12 3.15
349+
.. deprecated-removed:: 3.12 3.16
350350

351351

352352
Initializing and finalizing the interpreter
@@ -804,7 +804,7 @@ Process-wide parameters
804804
Use :c:func:`Py_DecodeLocale` to decode a bytes string to get a
805805
:c:expr:`wchar_t*` string.
806806
807-
.. deprecated-removed:: 3.11 3.15
807+
.. deprecated-removed:: 3.11 3.16
808808
809809
810810
.. c:function:: const char* Py_GetVersion()
@@ -929,7 +929,7 @@ Process-wide parameters
929929
930930
.. versionadded:: 3.1.3
931931
932-
.. deprecated-removed:: 3.11 3.15
932+
.. deprecated-removed:: 3.11 3.16
933933
934934
935935
.. c:function:: void PySys_SetArgv(int argc, wchar_t **argv)
@@ -950,7 +950,7 @@ Process-wide parameters
950950
951951
.. versionchanged:: 3.4 The *updatepath* value depends on :option:`-I`.
952952
953-
.. deprecated-removed:: 3.11 3.15
953+
.. deprecated-removed:: 3.11 3.16
954954
955955
956956
.. c:function:: void Py_SetPythonHome(const wchar_t *home)
@@ -971,4 +971,4 @@ Process-wide parameters
971971
Use :c:func:`Py_DecodeLocale` to decode a bytes string to get a
972972
:c:expr:`wchar_t*` string.
973973
974-
.. deprecated-removed:: 3.11 3.15
974+
.. deprecated-removed:: 3.11 3.16

Doc/c-api/unicode.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1953,7 +1953,7 @@ The following API is deprecated.
19531953
whether you selected a "narrow" or "wide" Unicode version of Python at
19541954
build time.
19551955
1956-
.. deprecated-removed:: 3.13 3.15
1956+
.. deprecated-removed:: 3.13 3.16
19571957
19581958
19591959
.. c:function:: int PyUnicode_READY(PyObject *unicode)

Doc/deprecations/c-api-pending-removal-in-3.15.rst

Lines changed: 0 additions & 85 deletions
Original file line numberDiff line numberDiff line change
@@ -46,88 +46,3 @@ Pending removal in Python 3.15
4646
The `pythoncapi-compat project
4747
<https://github.com/python/pythoncapi-compat/>`__ can be used to get
4848
:c:func:`PyConfig_Get` on Python 3.13 and older.
49-
50-
* Functions to configure Python's initialization, deprecated in Python 3.11:
51-
52-
* :c:func:`!PySys_SetArgvEx()`:
53-
Set :c:member:`PyConfig.argv` instead.
54-
* :c:func:`!PySys_SetArgv()`:
55-
Set :c:member:`PyConfig.argv` instead.
56-
* :c:func:`!Py_SetProgramName()`:
57-
Set :c:member:`PyConfig.program_name` instead.
58-
* :c:func:`!Py_SetPythonHome()`:
59-
Set :c:member:`PyConfig.home` instead.
60-
* :c:func:`!PySys_ResetWarnOptions`:
61-
Clear :data:`sys.warnoptions` and :data:`!warnings.filters` instead.
62-
63-
The :c:func:`Py_InitializeFromConfig` API should be used with
64-
:c:type:`PyConfig` instead.
65-
66-
* Global configuration variables:
67-
68-
* :c:var:`Py_DebugFlag`:
69-
Use :c:member:`PyConfig.parser_debug` or
70-
:c:func:`PyConfig_Get("parser_debug") <PyConfig_Get>` instead.
71-
* :c:var:`Py_VerboseFlag`:
72-
Use :c:member:`PyConfig.verbose` or
73-
:c:func:`PyConfig_Get("verbose") <PyConfig_Get>` instead.
74-
* :c:var:`Py_QuietFlag`:
75-
Use :c:member:`PyConfig.quiet` or
76-
:c:func:`PyConfig_Get("quiet") <PyConfig_Get>` instead.
77-
* :c:var:`Py_InteractiveFlag`:
78-
Use :c:member:`PyConfig.interactive` or
79-
:c:func:`PyConfig_Get("interactive") <PyConfig_Get>` instead.
80-
* :c:var:`Py_InspectFlag`:
81-
Use :c:member:`PyConfig.inspect` or
82-
:c:func:`PyConfig_Get("inspect") <PyConfig_Get>` instead.
83-
* :c:var:`Py_OptimizeFlag`:
84-
Use :c:member:`PyConfig.optimization_level` or
85-
:c:func:`PyConfig_Get("optimization_level") <PyConfig_Get>` instead.
86-
* :c:var:`Py_NoSiteFlag`:
87-
Use :c:member:`PyConfig.site_import` or
88-
:c:func:`PyConfig_Get("site_import") <PyConfig_Get>` instead.
89-
* :c:var:`Py_BytesWarningFlag`:
90-
Use :c:member:`PyConfig.bytes_warning` or
91-
:c:func:`PyConfig_Get("bytes_warning") <PyConfig_Get>` instead.
92-
* :c:var:`Py_FrozenFlag`:
93-
Use :c:member:`PyConfig.pathconfig_warnings` or
94-
:c:func:`PyConfig_Get("pathconfig_warnings") <PyConfig_Get>` instead.
95-
* :c:var:`Py_IgnoreEnvironmentFlag`:
96-
Use :c:member:`PyConfig.use_environment` or
97-
:c:func:`PyConfig_Get("use_environment") <PyConfig_Get>` instead.
98-
* :c:var:`Py_DontWriteBytecodeFlag`:
99-
Use :c:member:`PyConfig.write_bytecode` or
100-
:c:func:`PyConfig_Get("write_bytecode") <PyConfig_Get>` instead.
101-
* :c:var:`Py_NoUserSiteDirectory`:
102-
Use :c:member:`PyConfig.user_site_directory` or
103-
:c:func:`PyConfig_Get("user_site_directory") <PyConfig_Get>` instead.
104-
* :c:var:`Py_UnbufferedStdioFlag`:
105-
Use :c:member:`PyConfig.buffered_stdio` or
106-
:c:func:`PyConfig_Get("buffered_stdio") <PyConfig_Get>` instead.
107-
* :c:var:`Py_HashRandomizationFlag`:
108-
Use :c:member:`PyConfig.use_hash_seed`
109-
and :c:member:`PyConfig.hash_seed` or
110-
:c:func:`PyConfig_Get("hash_seed") <PyConfig_Get>` instead.
111-
* :c:var:`Py_IsolatedFlag`:
112-
Use :c:member:`PyConfig.isolated` or
113-
:c:func:`PyConfig_Get("isolated") <PyConfig_Get>` instead.
114-
* :c:var:`Py_LegacyWindowsFSEncodingFlag`:
115-
Use :c:member:`PyPreConfig.legacy_windows_fs_encoding` or
116-
:c:func:`PyConfig_Get("legacy_windows_fs_encoding") <PyConfig_Get>` instead.
117-
* :c:var:`Py_LegacyWindowsStdioFlag`:
118-
Use :c:member:`PyConfig.legacy_windows_stdio` or
119-
:c:func:`PyConfig_Get("legacy_windows_stdio") <PyConfig_Get>` instead.
120-
* :c:var:`!Py_FileSystemDefaultEncoding`, :c:var:`!Py_HasFileSystemDefaultEncoding`:
121-
Use :c:member:`PyConfig.filesystem_encoding` or
122-
:c:func:`PyConfig_Get("filesystem_encoding") <PyConfig_Get>` instead.
123-
* :c:var:`!Py_FileSystemDefaultEncodeErrors`:
124-
Use :c:member:`PyConfig.filesystem_errors` or
125-
:c:func:`PyConfig_Get("filesystem_errors") <PyConfig_Get>` instead.
126-
* :c:var:`!Py_UTF8Mode`:
127-
Use :c:member:`PyPreConfig.utf8_mode` or
128-
:c:func:`PyConfig_Get("utf8_mode") <PyConfig_Get>` instead.
129-
(see :c:func:`Py_PreInitialize`)
130-
131-
The :c:func:`Py_InitializeFromConfig` API should be used with
132-
:c:type:`PyConfig` to set these options. Or :c:func:`PyConfig_Get` can be
133-
used to get these options at runtime.
Lines changed: 84 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,87 @@
11
Pending removal in Python 3.16
22
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
33

4-
* The bundled copy of ``libmpdec``.
4+
* Functions to configure Python's initialization, deprecated in Python 3.11:
5+
6+
* :c:func:`!PySys_SetArgvEx()`:
7+
Set :c:member:`PyConfig.argv` instead.
8+
* :c:func:`!PySys_SetArgv()`:
9+
Set :c:member:`PyConfig.argv` instead.
10+
* :c:func:`!Py_SetProgramName()`:
11+
Set :c:member:`PyConfig.program_name` instead.
12+
* :c:func:`!Py_SetPythonHome()`:
13+
Set :c:member:`PyConfig.home` instead.
14+
15+
The :c:func:`Py_InitializeFromConfig` API should be used with
16+
:c:type:`PyConfig` instead.
17+
18+
* Global configuration variables:
19+
20+
* :c:var:`Py_DebugFlag`:
21+
Use :c:member:`PyConfig.parser_debug` or
22+
:c:func:`PyConfig_Get("parser_debug") <PyConfig_Get>` instead.
23+
* :c:var:`Py_VerboseFlag`:
24+
Use :c:member:`PyConfig.verbose` or
25+
:c:func:`PyConfig_Get("verbose") <PyConfig_Get>` instead.
26+
* :c:var:`Py_QuietFlag`:
27+
Use :c:member:`PyConfig.quiet` or
28+
:c:func:`PyConfig_Get("quiet") <PyConfig_Get>` instead.
29+
* :c:var:`Py_InteractiveFlag`:
30+
Use :c:member:`PyConfig.interactive` or
31+
:c:func:`PyConfig_Get("interactive") <PyConfig_Get>` instead.
32+
* :c:var:`Py_InspectFlag`:
33+
Use :c:member:`PyConfig.inspect` or
34+
:c:func:`PyConfig_Get("inspect") <PyConfig_Get>` instead.
35+
* :c:var:`Py_OptimizeFlag`:
36+
Use :c:member:`PyConfig.optimization_level` or
37+
:c:func:`PyConfig_Get("optimization_level") <PyConfig_Get>` instead.
38+
* :c:var:`Py_NoSiteFlag`:
39+
Use :c:member:`PyConfig.site_import` or
40+
:c:func:`PyConfig_Get("site_import") <PyConfig_Get>` instead.
41+
* :c:var:`Py_BytesWarningFlag`:
42+
Use :c:member:`PyConfig.bytes_warning` or
43+
:c:func:`PyConfig_Get("bytes_warning") <PyConfig_Get>` instead.
44+
* :c:var:`Py_FrozenFlag`:
45+
Use :c:member:`PyConfig.pathconfig_warnings` or
46+
:c:func:`PyConfig_Get("pathconfig_warnings") <PyConfig_Get>` instead.
47+
* :c:var:`Py_IgnoreEnvironmentFlag`:
48+
Use :c:member:`PyConfig.use_environment` or
49+
:c:func:`PyConfig_Get("use_environment") <PyConfig_Get>` instead.
50+
* :c:var:`Py_DontWriteBytecodeFlag`:
51+
Use :c:member:`PyConfig.write_bytecode` or
52+
:c:func:`PyConfig_Get("write_bytecode") <PyConfig_Get>` instead.
53+
* :c:var:`Py_NoUserSiteDirectory`:
54+
Use :c:member:`PyConfig.user_site_directory` or
55+
:c:func:`PyConfig_Get("user_site_directory") <PyConfig_Get>` instead.
56+
* :c:var:`Py_UnbufferedStdioFlag`:
57+
Use :c:member:`PyConfig.buffered_stdio` or
58+
:c:func:`PyConfig_Get("buffered_stdio") <PyConfig_Get>` instead.
59+
* :c:var:`Py_HashRandomizationFlag`:
60+
Use :c:member:`PyConfig.use_hash_seed`
61+
and :c:member:`PyConfig.hash_seed` or
62+
:c:func:`PyConfig_Get("hash_seed") <PyConfig_Get>` instead.
63+
* :c:var:`Py_IsolatedFlag`:
64+
Use :c:member:`PyConfig.isolated` or
65+
:c:func:`PyConfig_Get("isolated") <PyConfig_Get>` instead.
66+
* :c:var:`Py_LegacyWindowsFSEncodingFlag`:
67+
Use :c:member:`PyPreConfig.legacy_windows_fs_encoding` or
68+
:c:func:`PyConfig_Get("legacy_windows_fs_encoding") <PyConfig_Get>` instead.
69+
* :c:var:`Py_LegacyWindowsStdioFlag`:
70+
Use :c:member:`PyConfig.legacy_windows_stdio` or
71+
:c:func:`PyConfig_Get("legacy_windows_stdio") <PyConfig_Get>` instead.
72+
* :c:var:`!Py_FileSystemDefaultEncoding`, :c:var:`!Py_HasFileSystemDefaultEncoding`:
73+
Use :c:member:`PyConfig.filesystem_encoding` or
74+
:c:func:`PyConfig_Get("filesystem_encoding") <PyConfig_Get>` instead.
75+
* :c:var:`!Py_FileSystemDefaultEncodeErrors`:
76+
Use :c:member:`PyConfig.filesystem_errors` or
77+
:c:func:`PyConfig_Get("filesystem_errors") <PyConfig_Get>` instead.
78+
* :c:var:`!Py_UTF8Mode`:
79+
Use :c:member:`PyPreConfig.utf8_mode` or
80+
:c:func:`PyConfig_Get("utf8_mode") <PyConfig_Get>` instead.
81+
(see :c:func:`Py_PreInitialize`)
82+
83+
The :c:func:`Py_InitializeFromConfig` API should be used with
84+
:c:type:`PyConfig` to set these options. Or :c:func:`PyConfig_Get` can be
85+
used to get these options at runtime.
86+
87+
* :c:type:`Py_UNICODE` which was deprecated by :pep:`393`.

Doc/deprecations/index.rst

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,6 @@
11
Deprecations
22
============
33

4-
.. include:: pending-removal-in-3.15.rst
5-
64
.. include:: pending-removal-in-3.16.rst
75

86
.. include:: pending-removal-in-3.17.rst
@@ -22,8 +20,6 @@ Deprecations
2220
C API deprecations
2321
------------------
2422

25-
.. include:: c-api-pending-removal-in-3.15.rst
26-
2723
.. include:: c-api-pending-removal-in-3.16.rst
2824

2925
.. include:: c-api-pending-removal-in-3.18.rst

0 commit comments

Comments
 (0)