Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

gh-106847: Add -X warn_default_encoding in sys.flags Doc #106854

Merged
merged 5 commits into from
Jul 21, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
46 changes: 25 additions & 21 deletions Doc/library/sys.rst
Original file line number Diff line number Diff line change
Expand Up @@ -339,16 +339,16 @@
| Attribute | Explanation |
+=============================+==============================================+
| :const:`emscripten_version` | Emscripten version as tuple of ints |
| | (major, minor, micro), e.g. ``(3, 1, 8)``. |

Check warning on line 342 in Doc/library/sys.rst

View workflow job for this annotation

GitHub Actions / Docs / Docs

py:const reference target not found: emscripten_version
+-----------------------------+----------------------------------------------+
| :const:`runtime` | Runtime string, e.g. browser user agent, |
| | ``'Node.js v14.18.2'``, or ``'UNKNOWN'``. |

Check warning on line 345 in Doc/library/sys.rst

View workflow job for this annotation

GitHub Actions / Docs / Docs

py:const reference target not found: runtime
+-----------------------------+----------------------------------------------+
| :const:`pthreads` | ``True`` if Python is compiled with |
| | Emscripten pthreads support. |

Check warning on line 348 in Doc/library/sys.rst

View workflow job for this annotation

GitHub Actions / Docs / Docs

py:const reference target not found: pthreads
+-----------------------------+----------------------------------------------+
| :const:`shared_memory` | ``True`` if Python is compiled with shared |
| | memory support. |

Check warning on line 351 in Doc/library/sys.rst

View workflow job for this annotation

GitHub Actions / Docs / Docs

py:const reference target not found: shared_memory
+-----------------------------+----------------------------------------------+

.. availability:: Emscripten.
Expand Down Expand Up @@ -515,27 +515,28 @@
The :term:`named tuple` *flags* exposes the status of command line
flags. The attributes are read only.

============================= ==============================================================================================================
attribute flag
============================= ==============================================================================================================
:const:`debug` :option:`-d`
:const:`inspect` :option:`-i`
:const:`interactive` :option:`-i`
:const:`isolated` :option:`-I`
:const:`optimize` :option:`-O` or :option:`-OO`
:const:`dont_write_bytecode` :option:`-B`
:const:`no_user_site` :option:`-s`
:const:`no_site` :option:`-S`
:const:`ignore_environment` :option:`-E`
:const:`verbose` :option:`-v`
:const:`bytes_warning` :option:`-b`
:const:`quiet` :option:`-q`
:const:`hash_randomization` :option:`-R`
:const:`dev_mode` :option:`-X dev <-X>` (:ref:`Python Development Mode <devmode>`)
:const:`utf8_mode` :option:`-X utf8 <-X>`
:const:`safe_path` :option:`-P`
:const:`int_max_str_digits` :option:`-X int_max_str_digits <-X>` (:ref:`integer string conversion length limitation <int_max_str_digits>`)
============================= ==============================================================================================================
============================== ==============================================================================================================
attribute flag
============================== ==============================================================================================================
:const:`debug` :option:`-d`
:const:`inspect` :option:`-i`

Check warning on line 522 in Doc/library/sys.rst

View workflow job for this annotation

GitHub Actions / Docs / Docs

py:const reference target not found: debug
:const:`interactive` :option:`-i`
:const:`isolated` :option:`-I`

Check warning on line 524 in Doc/library/sys.rst

View workflow job for this annotation

GitHub Actions / Docs / Docs

py:const reference target not found: interactive
:const:`optimize` :option:`-O` or :option:`-OO`

Check warning on line 525 in Doc/library/sys.rst

View workflow job for this annotation

GitHub Actions / Docs / Docs

py:const reference target not found: isolated
:const:`dont_write_bytecode` :option:`-B`

Check warning on line 526 in Doc/library/sys.rst

View workflow job for this annotation

GitHub Actions / Docs / Docs

py:const reference target not found: optimize
:const:`no_user_site` :option:`-s`
:const:`no_site` :option:`-S`

Check warning on line 528 in Doc/library/sys.rst

View workflow job for this annotation

GitHub Actions / Docs / Docs

py:const reference target not found: no_user_site
:const:`ignore_environment` :option:`-E`

Check warning on line 529 in Doc/library/sys.rst

View workflow job for this annotation

GitHub Actions / Docs / Docs

py:const reference target not found: no_site
:const:`verbose` :option:`-v`
:const:`bytes_warning` :option:`-b`
:const:`quiet` :option:`-q`
:const:`hash_randomization` :option:`-R`
:const:`dev_mode` :option:`-X dev <-X>` (:ref:`Python Development Mode <devmode>`)
:const:`utf8_mode` :option:`-X utf8 <-X>`
:const:`safe_path` :option:`-P`
:const:`int_max_str_digits` :option:`-X int_max_str_digits <-X>` (:ref:`integer string conversion length limitation <int_max_str_digits>`)
:const:`warn_default_encoding` :option:`-X warn_default_encoding <-X>`
============================== ==============================================================================================================

.. versionchanged:: 3.2
Added ``quiet`` attribute for the new :option:`-q` flag.
Expand All @@ -554,6 +555,9 @@
Mode <devmode>` and the ``utf8_mode`` attribute for the new :option:`-X`
``utf8`` flag.

.. versionchanged:: 3.10
Added ``warn_default_encoding`` attribute for :option:`-X` ``warn_default_encoding`` flag.

.. versionchanged:: 3.11
Added the ``safe_path`` attribute for :option:`-P` option.

Expand Down
Loading