8000 Add missing 3.10/11 attributes to traceback module docs by Jackenmen · Pull Request #105043 · python/cpython · GitHub
[go: up one dir, main page]

Skip to content

Add missing 3.10/11 attributes to traceback module docs #105043

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

Closed
wants to merge 1,981 commits into from
Closed
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
1981 commits
Select commit Hold shift + click to select a range
e2924c0
gh-102936: typing: document performance pitfalls of protocols decorat…
miss-islington Mar 23, 2023
202e16e
gh-98239: Document that `inspect.getsource()` can raise `TypeError` (…
miss-islington Mar 23, 2023
60b2b58
[3.11] Minor readability improvement to the factor() recipe (GH-10297…
miss-islington Mar 23, 2023
8132aef
gh-102558: [Enum] fix AttributeError during member repr() (GH-102601)
miss-islington Mar 23, 2023
a4a039c
GH-100989: Revert Improve the accuracy of collections.deque docstring…
miss-islington Mar 24, 2023
fd43fb6
GH-100989: remove annotation from docstring (GH-102991)
miss-islington Mar 24, 2023
e075631
[3.11] gh-96931: Fix incorrect results in ssl.SSLSocket.shared_cipher…
miss-islington Mar 24, 2023
6716139
[3.11] gh-102027: Fix macro name (GH-102124) (#102916)
miss-islington Mar 24, 2023
c834a4c
gh-102873: logging.LogRecord docs: improve description of `msg` param…
miss-islington Mar 24, 2023
a08b65f
gh-102980: Add tests for pdf's display, alias and where commands (GH-…
miss-islington Mar 24, 2023
85c686a
[3.11] gh-101100: Document PyObject_ClearWeakRefs, gzip's name, and a…
hugovk Mar 25, 2023
aae91fa
[3.11] gh-103025: fix a ctypes doc typo (GH-103026) (#103029)
miss-islington Mar 25, 2023
e1094c6
Update pdb docs for arguments (GH-102965)
miss-islington Mar 25, 2023
b28f919
[3.11] gh-102281: Fix potential nullptr dereference + use of uninitia…
maxbachmann Mar 25, 2023
13df5d3
[3.11] GH-95494: Fix transport EOF handling in OpenSSL 3.0 (GH-95495)…
miss-islington Mar 27, 2023
5ba5ce4
gh-102558: [Enum] better handling of non-Enum EnumType classes (GH-10…
miss-islington Mar 27, 2023
abd6e97
[3.11] GH-102711: Fix warnings found by clang (GH-102712) (#103075)
miss-islington Mar 28, 2023
766038d
gh-103054: typing: Improve `Callable` type substitution tests (GH-103…
miss-islington Mar 29, 2023
d189e2d
[3.11] gh-102582: Fix invalid JSON in Doc/howto/logging-cookbook.rst …
miss-islington Mar 29, 2023
cbe14c8
gh-103097: Add workaround for Windows ARM64 compiler bug (GH-103098)
zooba Mar 29, 2023
ae42c1d
[3.11] gh-103112: Add http.client.HTTPResponse.read docstring and fix…
miss-islington Mar 29, 2023
1b40618
gh-103099: Link mypy docs from typing.rst (GH-103100)
miss-islington Mar 30, 2023
41e3ea1
Minor docs improvements fix for `codeop` (GH-103123)
miss-islington Mar 30, 2023
4664a7c
Quote literal tokens in standard format specifier grammar (GH-102902)
miss-islington Mar 31, 2023
0854bdf
gh-103109: Document ignore_warnings() test support helper (GH-103110)
miss-islington Apr 2, 2023
8236222
gh-102994: Profile docs has typo in example (GH-103074)
miss-islington Apr 2, 2023
cf72cc2
gh-98298, gh-74730: [Enum] update docs (GH-103163)
miss-islington Apr 3, 2023
5342f5e
gh-102549: [Enum] fail enum creation when data type raises in __init_…
miss-islington Apr 3, 2023
6abd048
[3.11] gh-103207: Add instructions to the macOS installer welcome dis…
ned-deily Apr 4, 2023
f3909b8
Python 3.11.3
pablogsal Apr 4, 2023
6258c3c
Improve some grammar in the socket docs (GH-103254)
miss-islington Apr 4, 2023
ff844aa
Post 3.11.3
pablogsal Apr 5, 2023
bd769d7
Merge remote-tracking branch 'upstream/3.11' into 3.11
pablogsal Apr 5, 2023
9357fc9
gh-81762: Clarify and simplify description of print's flush param (GH…
miss-islington Apr 5, 2023
09fb27f
gh-102899: Fix doc link for getting filesystem error handler (GH-102901)
miss-islington Apr 5, 2023
851e744
gh-99069: Consolidate checks for static_assert (GH-94766)
miss-islington Apr 5, 2023
0291397
[3.11] gh-103207: Fix Welcome formatting issues when macOS Installer …
ned-deily Apr 6, 2023
58e330a
[3.11] gh-93910: [Enum] remove member.member deprecation (GH-103236) …
ethanfurman Apr 6, 2023
123680f
[3.11] GH-102700: allow built-in modules to be submodules (GH-103162)…
miss-islington Apr 6, 2023
bbe04d9
gh-103266: Fix a typo in example code for bisect() function (GH-103267)
miss-islington Apr 7, 2023
8740fd8
gh-103256: Fix hmac algorithm to support fallback implementation (gh-…
miss-islington Apr 7, 2023
ecb09a8
[3.11] bpo-46523: fix tests rerun when `setUp[Class|Module]` fails (G…
ambv Apr 7, 2023
1b1f016
gh-74690: Add more tests for runtime-checkable protocols (GH-103347)
miss-islington Apr 7, 2023
b8d1623
gh-103272: regression test for getattr exception in property (GH-103336)
miss-islington Apr 7, 2023
70bc8c9
[3.11] GH-88013: Fix TypeError raised by ntpath.realpath in some case…
miss-islington Apr 7, 2023
29a1e89
gh-103329: Add regression test for PropertyMock with side effect (GH-…
miss-islington Apr 8, 2023
b4f3318
gh-75729: Fix os.spawn tests not handling spaces on Windows (GH-99150)
miss-islington Apr 8, 2023
31bec91
Docs: use Node.findall to avoid a deprecation warning (GH-99403)
miss-islington Apr 8, 2023
7b03d0f
gh-100574: add examples/links to the `strptime`/`strftime` docs (GH-1…
miss-islington Apr 8, 2023
77359a8
gh-103373: Improve documentation for `__mro_entries__` (GH-103374)
miss-islington Apr 8, 2023
4fa5fda
gh-103242: Migrate SSLContext.set_ecdh_curve not to use deprecated AP…
miss-islington Apr 8, 2023
da3b77b
CI: Do not allow merge if labelled DO-NOT-MERGE (GH-103337)
miss-islington Apr 9, 2023
4e284ff
gh-103395: Improve `typing._GenericAlias.__dir__` coverage (GH-103396)
miss-islington Apr 10, 2023
0f6319f
gh-97797: Mention `__metadata__` in docstrings of `typing.{_Annotated…
miss-islington Apr 10, 2023
b80e4c8
[3.11] gh-103059: Clarify gc.freeze documentation (GH-103058) (#103416)
miss-islington Apr 10, 2023
4a05392
Doc: Avoid error lexing multiprocessing docs code block on Pygments 2…
miss-islington Apr 11, 2023
a836d79
Docs: don't render files in includes/, they're for embedding only (GH…
miss-islington Apr 11, 2023
254494c
gh-99553: add tests for ExceptionGroup wrapping (GH-99615)
miss-islington Apr 11, 2023
07a2851
gh-103373: `__mro_entries__` docs: improve cross references (GH-103398)
miss-islington Apr 11, 2023
e715da6
gh-87864: Use correct function definition syntax in the docs (GH-103312)
miss-islington Apr 11, 2023
b5fe28d
gh-103237: Polish pdb docs (GH-103238)
miss-islington Apr 12, 2023
e643412
gh-103417: use time.monotonic in the example for sched.scheduler (GH-…
miss-islington Apr 12, 2023
804a973
gh-103365: [Enum] STRICT boundary corrections (GH-103494)
miss-islington Apr 13, 2023
3b929a7
[3.11] gh-103479: [Enum] require __new__ to be considered a data type…
ethanfurman Apr 13, 2023
2e0ead5
gh-103406: Modernize pos-only arguments usage in `test_signature` (GH…
miss-islington Apr 14, 2023
a3242c7
[3.11] gh-103180: Add CI timeouts to all GitHub Actions jobs (GH-1034…
sobolevn Apr 15, 2023
9f3f109
gh-103553: Improve `test_inspect`: add more assertions, remove unused…
miss-islington Apr 15, 2023
4c4ef50
GH-83893: Cross reference env. vars and -X command line options (GH-1…
miss-islington Apr 16, 2023
1dad3d1
GH-103484: Docs: add linkcheck allowed redirects entries for most cas…
miss-islington Apr 18, 2023
5a81a24
gh-103582: Remove last references to `argparse.REMAINDER` from docs (…
miss-islington Apr 19, 2023
2b5dbd1
Doc: Fix broken link to emscripten networking website (GH-99531)
miss-islington Apr 19, 2023
b2fdae9
[3.11] gh-103556: [inspect.Signature] disallow pos-or-kw params witho…
miss-islington Apr 22, 2023
7f6710b
[3.11] GH-103475: cache() and lru_cache() do not have a "call once" g…
miss-islington Apr 22, 2023
050b6b3
[3.11] Revert "Avoid error lexing multiprocessing docs code block on …
miss-islington Apr 22, 2023
a43dbe1
[3.11] gh-68654: Clarify subdirectories used by pkgutil.extend_path (…
miss-islington Apr 23, 2023
6e25228
[3.11] gh-81403: Fix for CacheFTPHandler in urllib (GH-13951) (#103705)
miss-islington Apr 23, 2023
ec29d0c
[3.11] gh-103449: Fix a bug in dataclass docstring generation (GH-103…
miss-islington Apr 23, 2023
4e9635e
[3.11] gh-103592: Add tests of `Literal` with `Enum` and `Union` of `…
miss-islington Apr 23, 2023
8642fdc
[3.11] GH-103484: Fix broken links reported by linkcheck (GH-103608) …
rffontenelle Apr 23, 2023
7b2ac6c
[3.11] gh-102310: Change error range for invalid bytes literals (GH-1…
miss-islington Apr 23, 2023
5054459
[3.11] gh-103668: Run pyugrade on idlelib (GH-103671) (#103730)
miss-islington Apr 24, 2023
dc08c7a
[3.11] gh-103685: Fix tkinter.Menu.index() for Tk 8.7 (GH-103686) (#1…
miss-islington Apr 24, 2023
16dabf9
[3.11] GH-78530: clarify docs for generators yielding tasks in `async…
kumaraditya303 Apr 24, 2023
e40db6e
[3.11] Descriptor HowTo: Update to include attributes added in Pytho…
miss-islington Apr 24, 2023
34df9e7
[3.11] Change 'dependant' to 'dependent' (GH-103745) (#103754)
miss-islington Apr 24, 2023
25406e5
[3.11] Add tests for empty range equality (GH-103751) (#103760)
miss-islington Apr 24, 2023
e0e1bee
[3.11] gh-103746: Test `types.UnionType` and `Literal` types together…
miss-islington Apr 24, 2023
a8489f7
[3.11] Revert "Add tests for empty range equality (GH-103751)" (GH-10…
miss-islington Apr 24, 2023
c8de883
[3.11] gh-99184: Bypass instance attribute access in `repr` of `weakr…
miss-islington Apr 24, 2023
6f92d3f
[3.11] gh-103765: Fix 'Warning: py:class reference target not found: …
miss-islington Apr 24, 2023
9f43643
[3.11] gh-101100: Fix Sphinx warnings in `argparse` module (#103289) …
hugovk Apr 24, 2023
56d50dd
[3.11] gh-103810: Fix broken references in dataclasses (GH-103811) (#…
ambv Apr 24, 2023
99db23d
[3.11] Also fail DO-NOT-MERGE when "awaiting changes" or "awaiting ch…
ambv Apr 25, 2023
a59dc1f
[3.11] gh-103559: Update bundled pip version to 23.1.1 (gh-103560) (#…
pfmoore Apr 25, 2023
05a2586
[3.11] gh-87452: Improve the Popen.returncode docs (#103771)
miss-islington Apr 25, 2023
026c3e9
[3.11] gh-91687: modernize dataclass example typing (GH-103773) (#103…
miss-islington Apr 25, 2023
93a9535
[3.11] gh-101517: fix line number propagation in code generated for e…
iritkatriel Apr 25, 2023
d9aafe2
[3.11] gh-103721: Improve cross-references for generic-alias docs (GH…
miss-islington Apr 25, 2023
f11ba1c
[3.11] gh-103578: Fix pdb reading code with non-utf8 encoding (GH-103…
miss-islington Apr 26, 2023
57c9634
[3.11] gh-103872: Update bundled pip version to 23.1.2 (gh-103874)
pfmoore Apr 26, 2023
97711de
[3.11] Docs build: Add upper bounds to transitive dependencies (GH-10…
miss-islington Apr 26, 2023
bce93c2
[3.11] gh-101879: docs - italicize argument in smtplib.SMPT() descrip…
miss-islington Apr 26, 2023
410c2ce
[3.11] gh-94300: Update datetime.strptime documentation (GH-95318) (#…
miss-islington Apr 26, 2023
c0b538b
[3.11] gh-101786: Clarify docs that asyncio.Server.sockets is a socke…
hauntsaninja Apr 26, 2023
4041251
gh-103883: Doc: Move PyUnicode_FromObject doc (GH-103913)
methane Apr 27, 2023
2cd1b9c
[3.11] gh-103607: Fix `pause_reading` to work when called from `conne…
miss-islington Apr 27, 2023
7f70f1c
[3.11] gh-103880: Fix `assertRaises` usage in `test_genericalias` (GH…
sobolevn Apr 27, 2023
d20758c
[3.11] gh-51574: Document behaviour of `mkdtemp` on 3.11 and lower (#…
AlexWaygood Apr 27, 2023
838bc90
[3.11] gh-98822: Add missing test directories to TESTSUBDIRS (#103942…
erlend-aasland Apr 27, 2023
dbc44fa
[3.11] GH-103903: Test the minimum Sphinx version in CI (#103904) (#1…
AA-Turner Apr 27, 2023
57d198e
gh-103935: Use `io.open_code()` when executing code in trace and prof…
zooba Apr 27, 2023
294398c
[3.11] Docs: fix dunders with too many underscores (#103955) (#103957)
erlend-aasland Apr 27, 2023
b3faf8c
[3.11] gh-100021: Document that sqlite3's executemany() discards resu…
erlend-aasland Apr 28, 2023
241f2e5
[3.11] gh-102950: Implement PEP 706 – Filter for tarfile.extractall (…
encukou Apr 28, 2023
4219074
[3.11] gh-98822: Correct a few TESTSUBDIRS entries (GH-103970)
zware Apr 28, 2023
fee3c91
[3.11] GH-103971: Fix incorrect locations for code following case blocks
gaogaotiantian Apr 28, 2023
9fbb614
[3.11] gh-99032: datetime docs: Encoding is no longer relevant (GH-93…
miss-islington Apr 29, 2023
86ef1ce
[3.11] Fix description of MAKE_CELL (#103986)
hauntsaninja Apr 29, 2023
ba16324
[3.11] Update name in acknowledgements and add mailmap (GH-103696) (#…
miss-islington Apr 30, 2023
2be3656
[3.11] Improve int test coverage (GH-104024) (#104026)
miss-islington May 1, 2023
2e5f1a1
[3.11] gh-88496: Fix IDLE test hang on macOS (GH-104025) (#104027)
miss-islington May 1, 2023
d8055b8
[3.11] Adjust expression from `==` to `!=` in alignment with the mean…
miss-islington May 1, 2023
1be8bed
[3.11] gh-104036: Fix direct invocation of test_typing (GH-104037) (#…
miss-islington May 1, 2023
0df7c3a
[3.11] gh-104035: Do not ignore user-defined `__{get,set}state__` in …
miss-islington May 1, 2023
723aacb
[3.11] gh-100458: Clarify Enum.__format__() change of mixed-in types …
miss-islington May 1, 2023
10db28b
[3.11] gh-104018: disallow "z" format specifier in %-format of byte s…
miss-islington May 1, 2023
9f191a1
[3.11] gh-88496: IDLE - fix another test on macOS (GH-104075) (#104076)
miss-islington May 2, 2023
6805e49
[3.11] gh-102997: Update macOS installer to SQLite 3.41.2. (GH-104080)
miss-islington May 2, 2023
b07bae6
[3.11] Replace Netlify with Read the Docs build previews (#103843) (#…
hugovk May 2, 2023
0d40264
[3.11] GH-103472: close response in HTTPConnection._tunnel (GH-103473…
miss-islington May 2, 2023
3e7e50e
[3.11] Improve assert_type phrasing (GH-104081) (#104084)
miss-islington May 2, 2023
61f1fbd
[3.11] gh-102997: Update Windows installer to SQLite 3.41.2. (#102999…
erlend-aasland May 2, 2023
5e76305
[3.11] GH-103484: Fix redirected permanently URLs (GH-104001) (#104088)
rffontenelle May 2, 2023
f9231a0
[3.11] gh-65022: Fix description of tuple return value in copyreg (GH…
hauntsaninja May 2, 2023
5386730
[3.11] gh-103590: do not wrap a single exception raised from a try-ex…
iritkatriel May 2, 2023
4536b2e
[3.11] gh-104049: do not expose on-disk location from SimpleHTTPReque…
miss-islington May 3, 2023
365e077
[3.11] gh-101100: Fix Sphinx warnings in `curses` and `curses.ascii` …
miss-islington May 3, 2023
8f94c94
[3.11] GH-97950: Allow translation of index directive content (GH-104…
miss-islington May 4, 2023
0056369
[3.11] GH-97950: Use new-style index directive ('module') (GH-103996)…
AA-Turner May 4, 2023
a9fcf01
[3.11] GH-97950: Use new-style index directive ('keyword') (GH-104153…
miss-islington May 4, 2023
693ef48
[3.11] GH-97950: Use new-style index directive ('operator') (GH-10415…
miss-islington May 4, 2023
c463796
[3.11] GH-97950: Use new-style index directive ('object') (GH-104158)…
miss-islington May 4, 2023
99e6314
[3.11] GH-97950: Use new-style index directive ('exception') (GH-1041…
AA-Turner May 4, 2023
6a970ae
[3.11] GH-97950: Use new-style index directive ('statement') (GH-1041…
miss-islington May 4, 2023
bb4369e
[3.11] gh-104112: link from cached_property docs to method-caching FA…
miss-islington May 4, 2023
81902d3
[3.11] gh-104106: Add gcc fallback of mkfifoat/mknodat for macOS (gh-…
corona10 May 5, 2023
a635d63
[3.11] gh-64658: Expand Argument Clinic return converter docs (#10417…
erlend-aasland May 5, 2023
4b11af0
[3.11] GH-97950: Use new-style index directive ('builtin') (GH-104164…
miss-islington May 6, 2023
10ee19b
[3.11] Rewrite the turtledemo makeGraphFrame method (GH-104224) (#104…
miss-islington May 6, 2023
cf1c25f
[3.11] gh-101640: Make argparse _print_message catch any write error …
miss-islington May 6, 2023
8f23cad
[3.11] gh-103886: Improve `builtins.__doc__` (GH-104179) (#104257)
miss-islington May 7, 2023
efcd4bc
[3.11] gh-104254: Document the optional keyword-only "context" argume…
miss-islington May 7, 2023
15ffcf7
[3.11] gh-104018: remove unused format "z" handling in string formatf…
miss-islington May 7, 2023
c5dafea
[3.11] Re-enable commented-out test in test_generators.py (GH-104130)…
miss-islington May 7, 2023
a09d390
[3.11] gh-96670: Raise SyntaxError when parsing NULL bytes (GH-97594)…
lysnikolaou May 7, 2023
19abf69
[3.11] gh-103225: Fixed zero lineno issue for pdb (#103265) (#104262)
gaogaotiantian May 7, 2023
681d502
[3.11] gh-100370: fix OverflowError in sqlite3.Connection.blobopen fo…
erlend-aasland May 8, 2023
065e2ae
[3.11] gh-104265 Disallow instantiation of `_csv.Reader` and `_csv.Wr…
miss-islington May 8, 2023
499b79d
[3.11] gh-102500: Remove mention of bytes shorthand (#104281) (#104288)
AlexWaygood May 8, 2023
d54f644
[3.11] gh-103193: Improve `getattr_static` test coverage (GH-104286) …
miss-islington May 8, 2023
8a6ff59
[3.11] GH-104145: Use fully-qualified cross reference types for the b…
miss-islington May 8, 2023
2ee2503
[3.11] GH-104284: Fix documentation gettext build (GH-104296) (#104299)
miss-islington May 8, 2023
b7622e7
[3.11] GH-104308: socket.getnameinfo should release the GIL (GH-10430…
miss-islington May 8, 2023
15624b4
[3.11] gh-102500: collections.abc.Buffer doesn't exist in 3.11 (#104317)
hauntsaninja May 9, 2023
97e1e43
[3.11] [doc] logging.rst - Change link to point directly to the Googl…
miss-islington May 9, 2023
4ed59b1
[3.11] gh-99889: Fix directory traversal security flaw in uu.decode()…
miss-islington May 9, 2023
663b321
[3.11] gh-104328: Fix typo in ``typing.Generic`` multiple inheritance…
miss-islington May 9, 2023
fffdbf4
[3.11] gh-102327: Extend docs for "url" and "headers" parameters to H…
miss-islington May 9, 2023
2fa14d4
[3.11] gh-48241: Clarify URL needs to be encoded when provided to url…
miss-islington May 9, 2023
b2171a2
[3.11] gh-103848: Adds checks to ensure that bracketed hosts found by…
miss-islington May 10, 2023
03abac2
[3.11] gh-103960: Dark mode: invert image brightness (GH-103983) (#10…
miss-islington May 10, 2023
a8e902d
[3.11] gh-104010: Separate and improve docs for `typing.get_origin` a…
miss-islington May 10, 2023
1cbf844
[3.11] gh-103247: clear the module cache in a test in test_importlib/…
miss-islington May 10, 2023
846a23d
[3.11] GH-87695: Fix OSError from `pathlib.Path.glob()` (GH-104292) (…
miss-islington May 10, 2023
7055088
[3.11] gh-101117: Improve accuracy of sqlite3.Cursor.rowcount docs (#…
erlend-aasland May 11, 2023
b4c1ca2
[3.11] gh-103204: `http.server` - Enforce that HTTP version numbers m…
miss-islington May 12, 2023
b90c922
[3.11] GH-94841: Fix usage of Py_ALWAYS_INLINE (GH-104439)
brandtbucher May 12, 2023
4ade7c3
[3.11] Fix refleak in super_descr_get (GH-104440)
brandtbucher May 12, 2023
fbb6def
[3.11] GH-104405: Add missing PEP 523 checks (GH-104441)
brandtbucher May 12, 2023
328b5dd
[3.11] gh-99836: IDLE - update news.txt for 3.11+ (#104445)
terryjreedy May 13, 2023
e794d46
[3.11] Add a mention of PYTHONBREAKPOINT to breakpoint() docs (GH-104…
miss-islington May 13, 2023
b87ccc3
[3.11] gh-75710: IDLE - add docstrings and comments to editor module …
miss-islington May 13, 2023
03f0d75
[3.11] GH-71383: IDLE - Document testing subsets of modules (GH-10446…
miss-islington May 14, 2023
f5f9975
[3.11] Minor improvements to typing docs (GH-104465) (#104475)
miss-islington May 14, 2023
8e79414
[3.11] gh-104337: Clarify random.gammavariate doc entry (GH-104410) …
miss-islington May 14, 2023
1afc0a9
[3.11] gh-98539: Make _SSLTransportProtocol.abort() safe to call when…
miss-islington May 14, 2023
a712c5f
[3.11] gh-67056: document that registering/unregistering an atexit fu…
miss-islington May 15, 2023
7779027
[3.11] gh-104461: Run tkinter test_configure_screen on X11 only (GH-1…
miss-islington May 16, 2023
52a18fe
[3.11] gh-104482: Fix error handling bugs in ast.c (#104514)
iritkatriel May 16, 2023
9cac6c4
[3.11] gh-104539: Fix indentation error in logging.config.rst (GH-104…
miss-islington May 16, 2023
f748fc9
[3.11] gh-75367: Fix data descriptor detection in inspect.getattr_sta…
miss-islington May 16, 2023
dece9c0
[3.11] gh-104494: Update certain Tkinter pack/place tests for Tk 8.7 …
miss-islington May 17, 2023
3ce7d57
[3.11] gh-87474: Fix file descriptor leaks in subprocess.Popen (GH-96…
miss-islington May 17, 2023
133bf09
[3.11] gh-103861: Fix Zip64 extensions not being properly applied in …
gpshead May 17, 2023
f106aef
[3.11] typing: Add more tests for TypeVar (GH-104571) (#104577)
JelleZijlstra May 17, 2023
0560fd3
[3.11] gh-104496: IDLE - fix About for mixed tcl/tk versions (GH-1045…
miss-islington May 17, 2023
610cc0a
[3.11] gh-102153: Start stripping C0 control and space chars in `urls…
miss-islington May 17, 2023
a8fc8b7
[3.11] gh-104340: Suppress warning about unawaited exception for clos…
miss-islington May 18, 2023
e96fb39
[3.11] gh-104499: IDLE - fix completions for tk aqua 8.7 (GH-104591) …
miss-islington May 18, 2023
99a162a
[3.11] gh-104499: Fix typo. (GH-104598) (#104599)
miss-islington May 18, 2023
3d52f7e
[3.11] gh-104629: Don't skip test_clinic if _testclinic is missing (G…
miss-islington May 18, 2023
ba39ea4
[3.11] gh-104623: Update Windows installer to use SQLite 3.42.0 (#104…
erlend-aasland May 18, 2023
d1bfefd
[3.11] gh-104623: Update macOS installer to SQLite 3.42.0 (GH-104643)
miss-islington May 19, 2023
aaeaf01
[3.11] gh-85984: Utilize new "winsize" functions from termios in pty …
miss-islington May 19, 2023
702ce87
[3.11] gh-96522: Fix deadlock in pty.spawn (GH-96639) (#104655)
ambv May 19, 2023
d78c3bc
[3.11] gh-104645: fix error handling in marshal tests (GH-104646) (#1…
miss-islington May 19, 2023
667e4ec
[3.11] gh-104615: don't make unsafe swaps in apply_static_swaps (GH-1…
carljm May 19, 2023
7b3bc95
[3.11] GH-102818: Do not call PyTraceBack_Here in sys.settrace trampo…
markshannon May 19, 2023
cd13f73
[3.11] gh-104659: Consolidate python examples in enum documentation (…
hugovk May 19, 2023
e5b6f38
[3.11] docs: fix wrong indentation causing rendering error in dis pag…
miss-islington May 19, 2023
2801b3f
[3.11] gh-104472: Skip `test_subprocess.ProcessTestCase.test_empty_en…
miss-islington May 19, 2023
dbb011a
[3.11] gh-103987: fix several crashes in mmap module (GH-103990) (#10…
miss-islington May 20, 2023
795b20e
[3.11] gh-56276: Add tests to test_compare (GH-3199) (#104694)
miss-islington May 20, 2023
89bd454
[3.11] gh-104679 Fixed syntax highlighting in turtle docs (GH-104682)…
millefalcon May 20, 2023
d45c1df
[3.11] gh-49174: document that the effect of calling gc.collect() dur…
miss-islington May 20, 2023
2e457bc
[3.11] gh-101857: Allow xattr detection on musl libc (GH-101858) (#10…
miss-islington May 21, 2023
b2e0201
[3.11] gh-104698: Fix reference leak in mmapmodule.c (GH-104700) (#10…
miss-islington May 21, 2023
dc0c41b
[3.11] Corrected identifier (GH-104713) (#104714)
miss-islington May 21, 2023
abb32de
[3.11] typing docs: Move some classes out of the "Generics" section (…
JelleZijlstra May 21, 2023
e033eda
[3.11] gh-104719: IDLE - delete useless monkeypatch of tokenize (GH-1…
miss-islington May 21, 2023
2ade563
[3.11] gh-103606: Improve error message from logging.config.FileConfi…
Agent-Hellboy May 21, 2023
d691de1
[3.11] gh-104683: `clinic.py`: Improve coverage for the `parse_conver…
AlexWaygood May 21, 2023
1692a16
[3.11] Add IPv6 into to the docstring for socket.getsockname (GH-1029…
miss-islington May 22, 2023
e95ca78
[3.11] gh-102978: Fix mock.patch function signatures for class and st…
miss-islington May 22, 2023
6f94bbf
[3.11] gh-104536: Improve `multiprocessing.process._cleanup` logic (G…
miss-islington May 22, 2023
be20e9c
[3.11] howto/urllib2: remove link to an outdated french translation (…
miss-islington May 22, 2023
ac12a6b
[3.11] gh-103726: Set up gcc-10 for ASAN (gh-103728) (#104794)
miss-islington May 23, 2023
582aadc
[3.11] gh-104271: Fix auto() fallback in case of mixed type Enum (GH-…
miss-islington May 23, 2023
6d00ae3
[3.11] gh-104372: Cleanup _posixsubprocess make_inheritable for async…
gpshead May 24, 2023
22618a8
[3.11] gh-104719: IDLE - test existence of all tokenize references. (…
miss-islington May 24, 2023
fa7d8ce
[3.11] gh-103207: The macOS 13 Ventura Installer.app permission probl…
ned-deily May 24, 2023
5e91167
[3.11] Improve test coverage for is_typeddict (GH-104884) (#104888)
miss-islington May 24, 2023
3b3f2e1
[3.11] gh-104874: Document NewType.__supertype__ (GH-104875) (#104907)
miss-islington May 24, 2023
76873ca
[3.11] Fix test_importlib.test_side_effect_import() (GH-104840) (#104…
miss-islington May 25, 2023
161fc18
[3.11] gh-104479: Update outdated tutorial floating-point reference (…
hauntsaninja May 26, 2023
b764347
[3.11] Fix typo in the tokenizer (GH-104950) (#104952)
miss-islington May 26, 2023
1342474
[3.11] gh-104943: Remove mentions of old Python versions (GH-104945) …
miss-islington May 26, 2023
f585ed1
[3.11] gh-104924: Fix `read()able` in `http.client` log messages (gh-…
miss-islington May 26, 2023
ca55247
[3.11] Remove raw asserts in test_typing.py (GH-104951) (#104979)
miss-islington May 26, 2023
4af56ec
[3.11] CI: Cache config.cache across runs to speed up build (GH-10480…
hugovk May 26, 2023
a632697
[3.11] gh-104984: remove kwargs and starargs from Call & ClassDef (GH…
miss-islington May 26, 2023
b9e2d80
[3.11] gh-104992: [What's New in 3.11] Document unittest.TestProgram.…
miss-islington May 27, 2023
d1a7d66
[3.11] CI: Precompute hash for config cache key in check_source job (…
itamaro May 27, 2023
dcfa816
[3.11] gh-104497: Make tkinter test pass with tk 8.7 (GH-104789) (#10…
miss-islington May 27, 2023
d34e58a
[3.11] gh-103921: Improve typing documentation (GH-104642) (#105007)
JelleZijlstra May 27, 2023
4fb9923
Add missing 3.10/11 attributes to traceback module docs
Jackenmen May 28, 2023
7dd1d8e
Add versionadded
Jackenmen May 28, 2023
a8a2af6
Update traceback.py
Jackenmen May 28, 2023
e3ea1f2
Add max_group_width/depth
Jackenmen May 28, 2023
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
Prev Previous commit
Next Next commit
gh-98298, gh-74730: [Enum] update docs (GH-103163)
fix FlagBoundary statements
add warning about reloading modules and enum identity
(cherry picked from commit 5ffc1e5)

Co-authored-by: Ethan Furman <ethan@stoneleaf.us>
  • Loading branch information
miss-islington and ethanfurman authored Apr 3, 2023
commit cf72cc25f600183c69e3639e78cfae3571f8d4d0
5 changes: 5 additions & 0 deletions Doc/howto/enum.rst
Original file line number Diff line number Diff line change
Expand Up @@ -371,6 +371,11 @@ below)::
>>> Color.BLUE == 2
False

.. warning::

It is possible to reload modules -- if a reloaded module contains
enums, they will be recreated, and the new members may not
compare identical/equal to the original members.

Allowed members and attributes of enumerations
----------------------------------------------
Expand Down
51 changes: 25 additions & 26 deletions Doc/library/enum.rst
Original file line number Diff line number Diff line change
Expand Up @@ -141,9 +141,8 @@ Module Contents
:func:`global_enum`

Modify the :class:`str() <str>` and :func:`repr` of an enum
to show its members as belonging to the module instead of its class.
Should only be used if the enum members will be exported to the
module global namespace.
to show its members as belonging to the module instead of its class,
and export the enum members to the global namespace.

:func:`show_flag_values`

Expand All @@ -170,6 +169,27 @@ Data Types
final *enum*, as well as creating the enum members, properly handling
duplicates, providing iteration over the enum class, etc.

.. method:: EnumType.__call__(cls, value, names=None, *, module=None, qualname=None, type=None, start=1, boundary=None)

This method is called in two different ways:

* to look up an existing member:

:cls: The enum class being called.
:value: The value to lookup.

* to use the ``cls`` enum to create a new enum (only if the existing enum
does not have any members):

:cls: The enum class being called.
:value: The name of the new Enum to create.
:names: The names/values of the members for the new Enum.
:module: The name of the module the new Enum is created in.
:qualname: The actual location in the module where this Enum can be found.
:type: A mix-in type for the new Enum.
:start: The first integer value for the Enum (used by :class:`auto`).
:boundary: How to handle out-of-range values from bit operations (:class:`Flag` only).

.. method:: EnumType.__contains__(cls, member)

Returns ``True`` if member belongs to the ``cls``::
Expand Down Expand Up @@ -262,26 +282,6 @@ Data Types
names will also be removed from the completed enumeration. See
:ref:`TimePeriod <enum-time-period>` for an example.

.. method:: Enum.__call__(cls, value, names=None, *, module=None, qualname=None, type=None, start=1, boundary=None)

This method is called in two different ways:

* to look up an existing member:

:cls: The enum class being called.
:value: The value to lookup.

* to use the ``cls`` enum to create a new enum:

:cls: The enum class being called.
:value: The name of the new Enum to create.
:names: The names/values of the members for the new Enum.
:module: The name of the module the new Enum is created in.
:qualname: The actual location in the module where this Enum can be found.
:type: A mix-in type for the new Enum.
:start: The first integer value for the Enum (used by :class:`auto`).
:boundary: How to handle out-of-range values from bit operations (:class:`Flag` only).

.. method:: Enum.__dir__(self)

Returns ``['__class__', '__doc__', '__module__', 'name', 'value']`` and
Expand Down Expand Up @@ -722,7 +722,6 @@ Data Types
.. attribute:: EJECT

Out-of-range values lose their *Flag* membership and revert to :class:`int`.
This is the default for :class:`IntFlag`::

>>> from enum import Flag, EJECT, auto
>>> class EjectFlag(Flag, boundary=EJECT):
Expand All @@ -734,8 +733,8 @@ Data Types

.. attribute:: KEEP

Out-of-range values are kept, and the *Flag* membership is kept. This is
used for some stdlib flags::
Out-of-range values are kept, and the *Flag* membership is kept.
This is the default for :class:`IntFlag`::

>>> from enum import Flag, KEEP, auto
>>> class KeepFlag(Flag, boundary=KEEP):
Expand Down
8 changes: 4 additions & 4 deletions Lib/enum.py
Original file line number Diff line number Diff line change
Expand Up @@ -1302,10 +1302,10 @@ def _reduce_ex_by_global_name(self, proto):
class FlagBoundary(StrEnum):
"""
control how out of range values are handled
"strict" -> error is raised [default for Flag]
"conform" -> extra bits are discarded
"eject" -> lose flag status [default for IntFlag]
"keep" -> keep flag status and all bits
"strict" -> error is raised
"conform" -> extra bits are discarded [default for Flag]
"eject" -> lose flag status
"keep" -> keep flag status and all bits [default for IntFlag]
"""
STRICT = auto()
CONFORM = auto()
Expand Down
0