Commit Graph

26107 Commits

Author SHA1 Message Date
Stanley 268129a74f
docs: Change links to label refs (#98454)
Co-authored-by: C.A.M. Gerlach <CAM.Gerlach@Gerlach.CAM>
2022-10-25 20:26:28 -07:00
Stanley 0ca6a4d640
gh-77753: Add example for values that compare equal in stdtypes (#98497)
Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
2022-10-25 19:54:27 -07:00
Stanley 4196ee5c8b
gh-84747: Add `async for` comment for StreamReader (#98633) 2022-10-25 19:16:18 -07:00
July Tikhonov 45644905ea
fix a typo in whatsnew/3.11 (#98603) 2022-10-25 16:42:54 -07:00
Jacob Walls faea6a131a
Fix typos in deprecation section of 3.11 What's New (#98628) 2022-10-25 16:35:53 -07:00
Jelle Zijlstra 5d8bf2b106
gh-97937: dis docs: add adaptive=False (#97939)
Co-authored-by: Shantanu <12621235+hauntsaninja@users.noreply.github.com>
Co-authored-by: Brandt Bucher <brandtbucher@gmail.com>
2022-10-25 15:58:04 -07:00
Eclips4 be0cf82ae4
gh-98602: [typing docs] Use quotes for forward reference in TypeVarTuple example (#98605) 2022-10-25 16:32:52 +01:00
Nikita Sobolev 5076108872
gh-98623: Fix base classes in `typing.rst` (#98626) 2022-10-25 07:06:13 -07:00
C.A.M. Gerlach dd13b23e49
gh-95913: Prepare Improved Modules in 3.11 WhatsNew for final edits (#98631)
* Add two line breaks and ref target labels to remaining subsections

* Fix a few out of order Improved Modules

* Fix a few minor textual formatting issues in sections

* Fix remaining Sphinx warnings in the Improved Modules section
2022-10-25 06:19:44 -07:00
Nikita Sobolev e3b9dd8e87
gh-98507: [typing docs] Rephrase "now supports `[]`" to "now supports subscripting" (#98508) 2022-10-24 19:10:25 +01:00
Kumar Aditya 2fdcc6f2cb
GH-91635: clarify docs about closing of transport in asyncio (#98563) 2022-10-24 10:52:02 -07:00
Nikita Sobolev 1a217f9ffc
gh-98500: Fix typing docs for `*View` classes (#98511) 2022-10-24 10:47:32 -07:00
Jelle Zijlstra c5a9d3f67f
gh-95913: Fix grammar for SpooledTemporaryFile 3.11 whatsnew entry (#98604)
Followup from #98312.
2022-10-24 09:45:43 -07:00
Johnny11502 c237076379
gh-97909: Mark up members of PyMemberDef (GH-98473)
Co-authored-by: T <tnie@tuta.io>
2022-10-24 16:13:38 +02:00
C.A.M. Gerlach e19c2b979f
gh-95913: Fix, sort & expand pending removal sect in 3.11 WhatsNew (GH-98583)
* Fix names/references of pending removal APIs

* Sort list of APIs pending removal alphabetically

* Add missing modules/submodules pending removal in 3.12

* Add table of unittest deprecated aliases to 3.11 What's New

Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
Co-authored-by: Petr Viktorin <encukou@gmail.com>
2022-10-24 15:35:28 +02:00
C.A.M. Gerlach f3f8b6fca5
gh-95913: Add io support for SpooledTemporaryFile in 3.11 Whatsnew (#98312) 2022-10-24 06:05:14 -07:00
C.A.M. Gerlach dfb5d272e6
gh-95913: Edit & expand Deprecated section of 3.11 WhatsNew (#98581)
* Refine Sphinx syntax and grammar/phrasing in Deprecated section items
* Organize into lang/builtins, modules & stdlib sections
* Convert PEP 594 module list into a grid to not waste as much space
* Add importlib.resources deprecated functions to section
2022-10-24 05:58:27 -07:00
C.A.M. Gerlach 22739a0e05
gh-95913: Edit, expand & format Bytecode sect in 3.11 WhatsNew (GH-98559) 2022-10-24 13:51:25 +01:00
C.A.M. Gerlach e81fad6b8a
gh-95913: Edit, link and sort 3.11 WhatsNew Build section (#98588) 2022-10-24 13:34:05 +01:00
C.A.M. Gerlach 43bef54a32
gh-95913: Edit, sort & expand 3.11 WhatsNew Porting section (#98585) 2022-10-24 13:33:31 +01:00
C.A.M. Gerlach 8dbec4dbe5
gh-95913: Edit, xref & sort 3.11 WhatsNew Removed section (#98584) 2022-10-24 13:33:16 +01:00
C.A.M. Gerlach e2dc223004
gh-95913 Add string section to Whatsnew with new Template methods (#98311) 2022-10-24 13:33:04 +01:00
Serhiy Storchaka 75a6fadf36
gh-91524: Speed up the regular expression substitution (#91525)
Functions re.sub() and re.subn() and corresponding re.Pattern methods
are now 2-3 times faster for replacement strings containing group references.

Closes #91524

Primarily authored by serhiy-storchaka Serhiy Storchaka
Minor-cleanups-by: Gregory P. Smith [Google] <greg@krypto.org>
2022-10-23 15:57:30 -07:00
Omkaar b6d5d5b60a
gh-98561: Fix a typo in typing (GH-98562) 2022-10-23 22:05:08 +08:00
wim glenn 833f275840
no-issue: typo fix in c-api/tuple.rst (gh-98560) 2022-10-23 19:46:56 +09:00
C.A.M. Gerlach f58631be11
gh-95913: Edit & expand Optimizations in 3.11 WhatsNew (#98426) 2022-10-22 20:14:11 +01:00
C.A.M. Gerlach 8f30267ab4
gh-95913: Copyedit & xref FrameInfo in Whatsnew inspect section (#98304) 2022-10-22 20:12:04 +01:00
Clément Robert 327fc1c6fa
[Enum docs]: fix order of arguments to isinstance() (#98542) 2022-10-22 12:29:00 +01:00
Stanley d9407b174c
gh-51511: Note that codecs.open()'s encoding parameter affects automatic conversion to binary mode (#94370) 2022-10-21 16:01:05 -07:00
Furkan Onder 4c1145bb37
bpo-2716: add license for audioop module (#19972) 2022-10-21 15:43:20 -07:00
Ethan Furman 3e95ffc7ae
gh-98298: [Enum] document ReprEnum, global_enum, and show_flag_values (GH-98455)
Co-authored-by: C.A.M. Gerlach <CAM.Gerlach@Gerlach.CAM>
2022-10-21 15:36:41 -07:00
Carl Meyer 82ccbf69a8
gh-91051: allow setting a callback hook on PyType_Modified (GH-97875) 2022-10-21 14:41:51 +01:00
Irit Katriel 8367ca136e
gh-98172: [doc] mention that except* handles naked exceptions (GH-98496) 2022-10-21 11:35:20 +01:00
Vinay Sajip a956c2fd55
[doc] Improve logging cookbook example. (GH-98481) 2022-10-20 12:46:03 +01:00
Noam Cohen a371a7e03e
gh-95023: Added os.setns and os.unshare functions (#95046)
Added os.setns and os.unshare to easily switch between namespaces
on Linux.

Co-authored-by: Christian Heimes <christian@python.org>
Co-authored-by: CAM Gerlach <CAM.Gerlach@Gerlach.CAM>
Co-authored-by: Victor Stinner <vstinner@python.org>
2022-10-20 11:08:54 +02:00
Rafael Fontenelle 52fcba6512
Doc: Remove title text from internal links (#98409)
Rely on the title of the linked internal page instead of putting the title. Sphinx will render with the title correctly, and this will reduce work for translators
2022-10-19 08:36:07 -07:00
Phil Elson 1a6bacb31f
[doc] Refresh the venv introduction documentation, and correct the statement about VIRTUAL_ENV (GH-98350)
Co-authored-by: C.A.M. Gerlach <CAM.Gerlach@Gerlach.CAM>
2022-10-19 15:49:34 +01:00
Hugo van Kemenade 50553004fe
Docs: Bump sphinx-lint and fix unbalanced inline literal markup (#98441)
Bump sphinx-lint and fix unbalanced inline literal markup
2022-10-19 14:00:28 +02:00
C.A.M. Gerlach ed827d5608
gh-95913: Edit zipfile Whatsnew section & add new APIs (#98314)
* Link ZipFile in What's New entry discussing it

* Add entry for new ZipFile.mkdir method

* Add entry for new zipfile.Path.stem/suffix/suffixes methods

* Add missing line breaks between zipfile bullet list items
2022-10-19 06:33:50 +02:00
C.A.M. Gerlach 251b8ccd2a
gh-95913: Add WhatsNew section for new logging APIs (#98320)
* Add entry for new logging.getLevelNamesMapping function

* Add entry for SysLogHandler.createSocket to whatsnew

* Add missing line break between logging bullet list items
2022-10-19 06:25:58 +02:00
Raymond Hettinger a53f637368
Fix markup indentation (GH-98424)
Fix markup
2022-10-18 20:14:41 -05:00
C.A.M. Gerlach fcae1954a2
gh-95914: Add links to 3.11 WhatsNew Summary items (#98416)
Add links to Summary items to where readers can learn more
2022-10-19 01:10:35 +02:00
Raymond Hettinger f4ead4874b
General improvements to the itertools docs (GH-98408) 2022-10-18 14:09:34 -05:00
Victor Stinner db03c8066a
gh-98393: os module reject bytes-like, only accept bytes (#98394)
The os module and the PyUnicode_FSDecoder() function no longer accept
bytes-like paths, like bytearray and memoryview types: only the exact
bytes type is accepted for bytes strings.
2022-10-18 17:52:31 +02:00
Julien Palard 2eb503e4dd
Doc: Found some remaining default roles. (GH-98392) 2022-10-18 15:46:18 +02:00
Julien Palard 0bbea545e3
Doc: missing underscore in hyperlink. (GH-98391) 2022-10-18 15:28:19 +02:00
C.A.M. Gerlach 73e5180faf
gh-95913: Copyedit, xref and organize enum section (#98295)
* Whatsnew: Convert literals in enum section to actual x-references

* Whatsnew: Rewrite enum section for clear and consistant phrasing

* Whatsnew: Combine directly related enum items instead of seperating them

* gh-98250: Describe __str__/__format__ changes more clearly/accurately

* Tweak enum section language per feedback from Ethan
2022-10-18 11:26:24 +02:00
C.A.M. Gerlach 0a0c7e5a7a
gh-95913: Prepare remaining Whatsnew sections for editing (#98342)
* Add line breaks & ref targets to Whatsnew to prepare for future changes

* Use standard heading underbar symbols for H4 sections

* Flatten Porting subsection; clarify scope of/link Python->CAPI sections

* Move C API pending deprecations to C API section, to match the others
2022-10-18 10:41:57 +02:00
Raymond Hettinger de3ece769a
GH-98363: Add itertools.batched() (GH-98364) 2022-10-17 18:53:45 -05:00
Raymond Hettinger 70732d8a4c
Move random selection recipes from itertools.rst to random.rst (GH-98369) 2022-10-17 17:30:49 -05:00
C.A.M. Gerlach 5fe0431474
gh-95913: Move subinterpreter exper removal to 3.11 WhatsNew (GH-98345)
Part of #95913
Forward port of #93306, which was a backport of #93185, to address #84694

This adds the What's New entry for the removal of the subinterpreter-related env variable, build-time flag, etc. As @ericsnowcurrently  was author of the original changes, I added him as a co-author to the commit.

This addition to the Python 3.11 What's New document were only made to the Python 3.11 branch during the backport process, and not added to the version in `main`. Forward-porting it ensures the docs retain these additions for the future, rather than being lost in a legacy Python versions, allows it to be be edited as part of #95913 , and avoids merge conflicts with routine back-ports of PRs touching it.

I've pulled in the addition exactly as-is with no modifications; any editing will be done in future PRs (and therefore can be reviewed and backported accordingly).

The one other such addition is forward-ported in #98344
2022-10-17 12:59:22 -07:00
C.A.M. Gerlach aafc53c0a6
gh-95914: Add What's New item describing PEP 670 changes (#98315) 2022-10-17 21:16:37 +02:00
Victor Stinner 1863302d61
gh-97669: Create Tools/build/ directory (#97963)
Create Tools/build/ directory. Move the following scripts from
Tools/scripts/ to Tools/build/:

* check_extension_modules.py
* deepfreeze.py
* freeze_modules.py
* generate_global_objects.py
* generate_levenshtein_examples.py
* generate_opcode_h.py
* generate_re_casefix.py
* generate_sre_constants.py
* generate_stdlib_module_names.py
* generate_token.py
* parse_html5_entities.py
* smelly.py
* stable_abi.py
* umarshal.py
* update_file.py
* verify_ensurepip_wheels.py

Update references to these scripts.
2022-10-17 12:01:00 +02:00
C.A.M. Gerlach bb38b39b33
gh-95913: Forward-port int/str security change to 3.11 What's New in main (#98344)
Add int/str security change from issue gh-95778 PRs gh-96499 / gh-95800

Co-authored-by: Gregory P. Smith <greg@krypto.org> [Google]
2022-10-16 18:43:13 -07:00
Raymond Hettinger ae19217867
GH-91415: Mention alphabetical sort ordering in the Sorting HOWTO (GH-98336) 2022-10-16 14:34:25 -05:00
Joannah Nanjekye 5c9302d03a
gh-85525: Remove extra row in doc (#98337)
* remove extra row

* 📜🤖 Added by blurb_it.

Co-authored-by: blurb-it[bot] <43283697+blurb-it[bot]@users.noreply.github.com>
2022-10-16 13:43:31 -04:00
Stanley 79fd6ccdbe
gh-85299: Add note warning about entry point guard for asyncio example (#93457) 2022-10-16 10:04:43 -07:00
Vinay Sajip f6b1e4048d
gh-98307: Add docstring and documentation for SysLogHandler.createSocket (GH-98319)
Co-authored-by: C.A.M. Gerlach <CAM.Gerlach@Gerlach.CAM>
2022-10-16 09:15:46 +01:00
Kumar Aditya 660f10248b
GH-94597: Deprecate child watcher getters and setters (#98215)
This is the next step for deprecating child watchers.

Until we've removed the API completely we have to use it, so this PR is mostly suppressing a lot of warnings when using the API internally.

Once the child watcher API is totally removed, the two child watcher implementations we actually use and need (Pidfd and Thread) will be turned into internal helpers.
2022-10-15 16:09:30 -07:00
Raymond Hettinger 3a639bbeac
Improve speed. Reduce auxiliary memory to 16.6% of the main array. (GH-98294) 2022-10-15 16:05:28 -05:00
Vinay Sajip 11c25a402d
[doc] Update logging cookbook with an example of custom handling of levels. (GH-98290)
Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
2022-10-15 21:23:06 +01:00
Simon Legner 02389658a4
docs(typing): harmonize "See PEP x for more details" (#97927) 2022-10-15 12:17:51 -07:00
Raymond Hettinger f4370318d6
Faster sieve() recipe (#98287) 2022-10-15 12:43:58 -05:00
BiscuitCandy 146f168fbf
gh-98227: executionmodel.rst: except* can also bind names (#98256)
Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
2022-10-15 09:04:08 -07:00
QuakeIV 4e2bd58af4
gh-96258: move Py_REFCNT and Py_SET_REFCNT to reference counting page (#96259) 2022-10-15 07:56:14 -07:00
Joannah Nanjekye bf786e6901
gh-85455: Add missing doc strings and improve docs (#21573)
* Add missing doc strings and improve docs

* Use imperative form

* Modify docstring wording
2022-10-15 09:31:06 -04:00
Joannah Nanjekye 05c042e707
gh-85525: Indicate supported sound header formats (#21575)
* Indicate supported sound header formats

* modify file names

Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
2022-10-15 09:30:05 -04:00
Julien Palard 3c4cbd177f
gh-91485: Doc: Using Python syntax to document builtin Python functions. (GH-96579) 2022-10-15 12:19:35 +02:00
Nikita Sobolev 4414586172
Mark all targets in `Doc/Makefile` as `PHONY` (GH-98189) 2022-10-12 21:40:47 +02:00
Stanley e9569ec43e
gh-96265: Formatting changes for faq/general (#98129)
* Some formatting changes for general faq

* Use list for Python versioning

Co-authored-by: Ezio Melotti <ezio.melotti@gmail.com>

* New line for list, list for a/b/rc

* Line wrap for 80 chars

* More line wrap

* Remove PythonWin mention.

Co-authored-by: C.A.M. Gerlach <CAM.Gerlach@Gerlach.CAM>

Co-authored-by: Ezio Melotti <ezio.melotti@gmail.com>
Co-authored-by: C.A.M. Gerlach <CAM.Gerlach@Gerlach.CAM>
2022-10-12 18:04:41 +02:00
Jelle Zijlstra 5f8ca1b796
tutorial: remove "with single quotes" (#98204)
Closes #91856.

On Windows double quotes are sometimes better, on Unix usually
single quotes. It's not our place to explain that, so just don't.
2022-10-12 09:00:51 -07:00
Shantanu c39a0c3354
gh-65046: Link to logging cookbook from asyncio docs (#98207) 2022-10-11 21:42:57 -07:00
Stanley 3b33c2010a
Formatting fixes in contextlib docs (#98111) 2022-10-11 20:56:32 -07:00
MonadChains e3bf125c81
gh-95276: Add callable entry to the glossary (#95738) 2022-10-11 19:41:08 -07:00
Shantanu ed6344eed0
gh-96130: Rephrase use of "typecheck" verb for clarity (#98144)
I'm sympathetic to the issue report, especially in case this helps
clarify to new users that Python itself does not do type checking at runtime
2022-10-11 19:37:58 -07:00
Jelle Zijlstra 5ecf961640
gh-98172: Fix formatting in `except*` docs (#98173) 2022-10-11 09:13:56 -07:00
Julien Palard 4067c6d7fe
gh-86404: Doc: Drop now unused make suspicious and rstlint. (GH-98179)
They have been replaced by
[sphinx-lint](https://github.com/sphinx-contrib/sphinx-lint).
2022-10-11 15:31:33 +02:00
Stanley f0a680007f
gh-71616: Add note to warn against general translation of saxutils.escape() (#93450)
* Add note to warn against general translation of saxutils.escape()

* Use more direct wording
2022-10-11 05:27:49 -04:00
Vinay Sajip 6a757da080
gh-88452: Add a warning about non-portability of environments. (GH-98155) 2022-10-10 19:27:52 +01:00
Stanley 187e853690
gh-83940: os docs: Improve wording for getenv/getenvb (#98113) 2022-10-10 06:43:01 -07:00
Julien Palard 571e23d991
doc: remove a misleading statement. (GH-98093) 2022-10-10 09:01:16 +02:00
da-woods c459fedf7c
Fix types in buffer/memoryview docs (#98118)
The definition of obj in the `Py_buffer` struct is as a PyObject*
ec091bd47e/Include/pybuffer.h (L22)

PyMemoryView_GET_BASE returns `.obj` - thus its return type
should be a PyObject* (or at least a void*). It definitely
doesn't return `Py_buffer`
2022-10-09 17:55:53 -07:00
Stanley 281a3f18cc
gh-56133: copyreg docs: Clarify function/constructor parameter (#95497) 2022-10-09 17:51:02 -07:00
Carl Meyer f1879690aa
Update whatsnew instructions for GitHub (#98124) 2022-10-10 00:29:25 +02:00
Géry Ogam 2d2e01aa4c
Minor edits to the Descriptor HowTo Guide (GH-24901)
Co-authored-by: Raymond Hettinger <rhettinger@users.noreply.github.com>
2022-10-08 20:54:21 -05:00
Kumar Aditya d8765284f3
GH-94597: deprecate `SafeChildWatcher`, `FastChildWatcher` and `MultiLoopChildWatcher` child watchers (#98089) 2022-10-08 13:52:19 -07:00
Pablo Galindo Salgado 83eb827247
gh-97922: Run the GC only on eval breaker (#97920) 2022-10-08 07:57:09 -07:00
Hugo van Kemenade 296313002f
gh-97913 Docs: Add walrus operator to the index (#97921)
* Add walrus operator to the index

* Add named expression to the index

Co-authored-by: Mariatta Wijaya <Mariatta@users.noreply.github.com>

* Fix indentation and add missing newline

Co-authored-by: Ezio Melotti <ezio.melotti@gmail.com>

Co-authored-by: Mariatta Wijaya <Mariatta@users.noreply.github.com>
Co-authored-by: Ezio Melotti <ezio.melotti@gmail.com>
2022-10-08 08:54:16 +02:00
partev 840fd19590
[doc] Fix broken links to C extensions accelerating stdlib modules (#96914)
Co-authored-by: Łukasz Langa <lukasz@langa.pl>
Co-authored-by: C.A.M. Gerlach <CAM.Gerlach@Gerlach.CAM>
2022-10-07 22:55:35 -07:00
JasonYZ 6b485629d2
gh-97822: Fix http.server documentation reference to test() function (#98027)
Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
2022-10-07 21:46:23 -07:00
Carl Meyer e82d977eb0
gh-91052: Add PyDict_Unwatch for unwatching a dictionary (#98055) 2022-10-07 17:37:46 -07:00
Stanley 0f498f1a95
gh-57179: Add note on symlinks for os.walk (#94799) 2022-10-07 15:51:50 -07:00
Stanley 5eaf4d6101
gh-61105: Add default param, note on using cookiejar subclass (#95427) 2022-10-07 15:21:13 -07:00
Jelle Zijlstra 0f111f53c1
gh-96073: fix backticks in NEWS entry (GH-98056)
Automerge-Triggered-By: GH:JelleZijlstra
2022-10-07 14:44:56 -07:00
Stanley eed80458e8
gh-91708: Revert params note in urllib.parse.urlparse table (#96699)
Revert params note in urllib.parse.urlparse table
2022-10-07 12:19:36 -07:00
Stanley 3a7e955858
gh-96265: Fix some formatting in faq/design.rst (#96924)
Co-authored-by: Ezio Melotti <ezio.melotti@gmail.com>
Co-authored-by: C.A.M. Gerlach <CAM.Gerlach@Gerlach.CAM>
2022-10-07 12:15:41 -07:00
Stanley fde74be61b
gh-73196: Add namespace/scope clarification for inheritance section (#92840)
Add namespace/scope clarification for inheritance section
2022-10-07 12:04:14 -07:00
Nikita Sobolev 586cfb0131
gh-97956: Mention `generate_global_objects.py` in `AC How-To` (#97957) 2022-10-07 11:54:45 -07:00
180909 c81c64ca58
gh-96959: Update HTTP links which are redirected to HTTPS (#98039) 2022-10-07 11:52:45 -07:00
Eric Wieser c7b2204996
Add a warning message about PyOS_snprintf (#95993) 2022-10-07 11:49:53 -07:00
Stanley 676d8ef380
gh-65496: Correct wording on csv's skipinitialspace argument (#96170) 2022-10-07 11:15:34 -07:00
Stanley 4a74e6ab38
gh-64921: Clarify wording for open()'s newline arg (#96171) 2022-10-07 11:12:08 -07:00
Victor Stinner 002252c4ad
gh-97669: Move difflib examples to Doc/includes/ (#97964)
Remove diff.py and ndiff.py scripts of Tools/scripts/: move them to
Doc/includes/.

* diff.py and ndiff.py files are no longer executable. Remove also
  their shebang ("#!/usr/bin/env python3").
* Remove the -profile command from ndiff.py to simply the code.
* Remove ndiff.py copyright and history command. The Python
  documentation examples are distributed under the "Zero Clause BSD
  License".
2022-10-07 10:57:48 -07:00
Christopher Chianelli 6592a62ec2
gh-71316: Update dis documentation to include changes to jump arguments (GH-95798) 2022-10-07 14:54:21 +01:00
Raymond Hettinger e500cc0451
Misc updates to the itertools recipes and tests (GH-98018) 2022-10-07 03:37:21 -05:00
Julien Palard 66cc46b2e4
Doc: sphinx-lint finds two other default roles. (GH-98019) 2022-10-07 09:10:51 +02:00
Barry Warsaw 13d4489142
gh-86298: Ensure that __loader__ and __spec__.loader agree in warnings.warn_explicit() (GH-97803)
In `_warnings.c`, in the C equivalent of `warnings.warn_explicit()`, if the module globals are given (and not None), the warning will attempt to get the source line for the issued warning.  To do this, it needs the module's loader.

Previously, it would only look up `__loader__` in the module globals.  In https://github.com/python/cpython/issues/86298 we want to defer to the `__spec__.loader` if available.

The first step on this journey is to check that `loader == __spec__.loader` and issue another warning if it is not.  This commit does that.

Since this is a PoC, only manual testing for now.

```python
# /tmp/foo.py
import warnings

import bar

warnings.warn_explicit(
    'warning!',
    RuntimeWarning,
    'bar.py', 2,
    module='bar knee',
    module_globals=bar.__dict__,
    )
```

```python
# /tmp/bar.py
import sys
import os
import pathlib

# __loader__ = pathlib.Path()
```

Then running this: `./python.exe -Wdefault /tmp/foo.py`

Produces:

```
bar.py:2: RuntimeWarning: warning!
  import os
```

Uncomment the `__loader__ = ` line in `bar.py` and try it again:

```
sys:1: ImportWarning: Module bar; __loader__ != __spec__.loader (<_frozen_importlib_external.SourceFileLoader object at 0x109f7dfa0> != PosixPath('.'))
bar.py:2: RuntimeWarning: warning!
  import os
```

Automerge-Triggered-By: GH:warsaw
2022-10-06 19:32:53 -07:00
Hugo van Kemenade fa2d43e518
Docs: Fix backtick errors found by sphinx-lint (#97998)
Co-authored-by: Ezio Melotti <ezio.melotti@gmail.com>
2022-10-06 18:01:30 -07:00
Nikita Sobolev 27025e158c
gh-97850: Remove deprecated functions from `importlib.utils` (#97898)
* gh-97850: Remove deprecated functions from `importlib.utils`

* Rebase and remove `set_package` from diff
2022-10-06 17:57:10 -07:00
Xiao Chen 4875433682
Remove extra spaces in custom openSSL documentation. (#93568) 2022-10-06 17:42:08 -07:00
Guido van Rossum 09de8d7aaf
GH-90985: Revert "Deprecate passing a message into cancel()" (#97999)
Reason: we were too hasty in deprecating this.
We shouldn't deprecate it before we have a replacement.
2022-10-06 17:30:27 -07:00
Carl Meyer a4b7794887
GH-91052: Add C API for watching dictionaries (GH-31787) 2022-10-07 01:08:00 +01:00
Brett Cannon e1c4d56fdd
gh-65961: Do not rely solely on `__cached__` (GH-97990)
Make sure `__spec__.cached` (at minimum) can be used.
2022-10-06 15:40:22 -07:00
Brett Cannon f8edc6ff53
gh-97850: Remove the open issues section from the import reference (#97935)
Remove the open issues section from the import reference

Tracking in https://github.com/python/cpython/issues/97850 instead.
2022-10-06 14:01:06 -07:00
Hugo van Kemenade 993de50e44
Docs: pin sphinx-lint (GH-97992) 2022-10-06 13:58:41 -07:00
Barry Warsaw effc25f7f2
Add Pynche's move to the What's new in 3.11 (#97974)
* Add Pynche's move to the What's new in 3.11

* Update Doc/whatsnew/3.11.rst

Co-authored-by: Ezio Melotti <ezio.melotti@gmail.com>

Co-authored-by: Ezio Melotti <ezio.melotti@gmail.com>
2022-10-06 13:29:52 -07:00
Jason R. Coombs 8af04cdef2
gh-97781: Apply changes from importlib_metadata 5. (GH-97785)
* gh-97781: Apply changes from importlib_metadata 5.

* Apply changes from upstream

* Apply changes from upstream.
2022-10-06 15:25:24 -04:00
Terry Jan Reedy 2b5f1360ea
gh-86482: Document assignment expression need for ()s (#23291)
Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
2022-10-06 12:24:17 -07:00
Adam Turner f612565bd3
gh-93738: Disallow pre-v3 syntax in the C domain (#97962)
Also, disable using invalid sphinx-lint 0.6.2.
2022-10-06 10:11:37 -07:00
180909 cd0fde27f9
gh-95986: Fix the example using match keyword (#95989) 2022-10-06 09:52:21 -07:00
180909 0d68879104
gh-95691: Doc BufferedWriter and BufferedReader (#95703) 2022-10-05 16:57:42 -07:00
Guido van Rossum 74ea204634
GH-88968: Add notes about socket ownership transfers (#97936) 2022-10-05 16:42:01 -07:00
Brett Cannon c206e53bb7
gh-65961: Raise `DeprecationWarning` when `__package__` differs from `__spec__.parent` (#97879)
Also remove `importlib.util.set_package()` which was already slated for removal.

Co-authored-by: Eric Snow <ericsnowcurrently@gmail.com>
2022-10-05 15:00:45 -07:00
Simon Legner 2016bc54a2
docs(typing): add "see PEP 675" to LiteralString (#97926) 2022-10-05 13:08:07 -07:00
Barry Warsaw 5dc3599135
gh-97850: Remove all known instances of module_repr() (#97876)
Remove all known instances of module_repr()
2022-10-05 11:42:26 -07:00
Tshepang Mbambo 815008a3a5
I changed my surname early this year (#96671)
* I recently changed my name

* Update ACKS
2022-10-05 11:16:45 -07:00
Adam Turner 0031e62973
gh-93738: Documentation C syntax (:c:type:<C type> -> :c:expr:<C type>) (#97768)
:c:type:`<C type>` -> :c:expr:`<C type>`

Co-authored-by: Łukasz Langa <lukasz@langa.pl>
2022-10-05 11:01:14 -07:00
180909 d6062d1170
GH-95172 Make the same version `versionadded` oneline (#95172)
* Make the same version versionadded oneline

* Format versionadded for enum.rst

* Format versionadded

A single line versionadded was reading better.

Co-authored-by: Senthil Kumaran <senthil@python.org>
2022-10-05 10:52:59 -07:00
Adam Turner 0e72606dd4
gh-93738: Documentation C syntax (Function glob patterns -> literal markup) (#97774) 2022-10-05 08:22:28 -07:00
Serhiy Storchaka e3ef400be7
gh-74696: Pass root_dir to custom archivers which support it (GH-94251)
Co-authored-by: Éric <merwok@netwok.org>
2022-10-05 12:48:59 +03:00
Jia Junjie 4b83cd0b22
gh-97661: Improve accuracy of sqlite3.Cursor.fetchone docs (#97662)
Co-authored-by: C.A.M. Gerlach <CAM.Gerlach@Gerlach.CAM>
2022-10-05 10:47:54 +02:00
Guido van Rossum 8079bef56f
GH-96704: Add {Task,Handle}.get_context(), use it in call_exception_handler() (#96756)
Co-authored-by: Kumar Aditya <59607654+kumaraditya303@users.noreply.github.com>
2022-10-04 23:49:10 -07:00
Adam Turner c70c8b6976
gh-93738: Documentation C syntax (:c:type:`PyTypeObject*` -> :c:expr:`PyTypeObject*`) (#97778)
Co-authored-by: Ezio Melotti <ezio.melotti@gmail.com>
2022-10-04 17:56:20 -07:00
Athos Ribeiro 0ceafa7fa4
Add re.VERBOSE flag documentation example (#97678)
The current re.VERBOSE documentation example leaves space for ambiguous
interpretation. One may read that spaces within the `(?:` token are
spaces inside the non-capturing group (such as `(?: )`). This patch
removes the ambiguity by including examples after the statement.
2022-10-04 17:39:42 -07:00
Shahriar Heidrich 395b66a0ae
gh-97654: Add auto exception chaining example to tutorial (#97703)
Add auto exception chaining example to tutorial
2022-10-04 17:36:04 -07:00
C.A.M. Gerlach 4e731814d7
gh-95913: Copyedit/improve Implementation Changes What's New section (#97720)
* Add and refine reST/Sphinx syntax for implementation changes section

* Clarify and refine wording in the Implementation Changes section

* Elide unnecessary comma

Co-authored-by: Ezio Melotti <ezio.melotti@gmail.com>

Co-authored-by: Ezio Melotti <ezio.melotti@gmail.com>
2022-10-05 02:03:58 +02:00
Adam Turner 6b3d4db02e
gh-93738: Documentation C syntax (:c:type: to :c:expr:, misc. cases) (#97775)
* :c:type: to :c:expr:

* Update Doc/whatsnew/2.4.rst
2022-10-04 16:32:27 -07:00
Adam Turner 192d401ba5
gh-93738: Documentation C syntax (:c:type:`FILE` -> :c:expr:`FILE`) (#97769)
:c:type:`FILE` -> :c:expr:`FILE`
2022-10-04 16:27:29 -07:00
Adam Turner 8b211b4cdb
gh-93738: Documentation C syntax (:c:type:`TYPE` -> :c:expr:`TYPE`) (#97770)
:c:type:`TYPE` -> :c:expr:`TYPE`
2022-10-04 16:26:36 -07:00
Adam Turner a0f5599aac
gh-93738: Documentation C syntax (Use `c:struct`) (#97772)
Use `c:struct`
2022-10-04 16:26:14 -07:00
Adam Turner fa59bda8d3
gh-93738: Documentation C syntax (:c:data:`view->obj` -> :c:expr:`view->obj`) (#97773)
:c:data:`view->obj` -> :c:expr:`view->obj`
2022-10-04 16:18:09 -07:00
C.A.M. Gerlach a77d9dedcd
gh-95913: Copyedit/improve Other Language Changes What's New section (#97719)
* Add/refine cross references to items in other lang changes section

* Unify context manager exception changes into single non-repetitive item

* More clearly describe the intent and consequences of the -P option

* Apply minor clarifications & copyedits to rest of section

* Tweak the formatting of module references

Co-authored-by: Ezio Melotti <ezio.melotti@gmail.com>

Co-authored-by: Ezio Melotti <ezio.melotti@gmail.com>
2022-10-05 01:16:37 +02:00
Adam Turner 0bf6a617ed
gh-93738: Documentation C syntax (:c:type:`PyObject` -> :c:expr:`PyObject`) (#97776)
:c:type:`PyObject` -> :c:expr:`PyObject`
2022-10-04 16:13:03 -07:00
Adam Turner 4ebb025031
gh-93738: Documentation C syntax (:c:type:`PyInterpreterState *` -> :c:expr:`PyInterpreterState *`) (#97777)
:c:type:`PyInterpreterState *` -> :c:expr:`PyInterpreterState *`
2022-10-04 16:12:22 -07:00
Adam Turner 510baa429a
gh-93738: Documentation C syntax (:c:type:`PyTupleObject*` -> :c:expr:`PyTupleObject*`) (#97780)
:c:type:`PyTupleObject*` -> :c:expr:`PyTupleObject*`
2022-10-04 16:11:54 -07:00
Adam Turner 9ebc50866b
gh-93738: Documentation C syntax (:c:type:`PyBytesObject*` -> :c:expr:`PyBytesObject*`) (#97782)
:c:type:`PyBytesObject*` -> :c:expr:`PyBytesObject*`
2022-10-04 16:11:34 -07:00
Adam Turner 898834e27b
gh-93738: Documentation C syntax (:c:type:`PyUnicodeObject*` -> :c:expr:`PyUnicodeObject*`) (#97783)
:c:type:`PyUnicodeObject*` -> :c:expr:`PyUnicodeObject*`
2022-10-04 16:11:20 -07:00
Adam Turner a081cae2a2
gh-93738: Documentation C syntax (:c:type:`Py_UNICODE*` -> :c:expr:`Py_UNICODE*`) (#97784)
:c:type:`Py_UNICODE*` -> :c:expr:`Py_UNICODE*`
2022-10-04 16:10:57 -07:00
cousteau ff28d8926d
gh-88355: Fix backslashes in AF_PIPE (#96543)
Fix backslashes in AF_PIPE (#88355)

The correct syntax for AF_PIPE addresses is `\\.\pipe\blahblah`, not `\.\pipe{blahblah}`, but the syntax markup messed up the backslashes.
2022-10-04 15:54:03 -07:00
C.A.M. Gerlach 985958187d
gh-95913: Move py.exe to appropriate What's New section & refine text (#97718)
* Move Windows py.exe improvements from Typing section to New Features

* Add ref target label and use literal for py.exe

* Be clearer/explict about what legacy version arg components reprisent

* Apply other minor clarity and textual fixes to py.exe launcher text

* Refine phrasing of legacy sentence of py.exe desc

Co-authored-by: Ezio Melotti <ezio.melotti@gmail.com>

Co-authored-by: Ezio Melotti <ezio.melotti@gmail.com>
2022-10-05 00:50:34 +02:00
Ev2geny 743453a554
gh-58451: Add optional delete_on_close parameter to NamedTemporaryFile (GH-97015) 2022-10-04 23:37:33 +01:00
Daniel Giger 7acb93f0d4
gh-96448: fix documentation for _thread.lock.acquire (#96449)
* fix documentation for _thread.lock.acquire

* update formatting of _thread.lock.acquire() doc
2022-10-04 15:18:04 -07:00
Inada Naoki 87679a6e60
gh-90301: Doc: Add references to PEP 686 (#96816)
Doc: Add references to PEP 686.
2022-10-04 15:04:44 -07:00
Guido van Rossum 9fbfa42ece
GH-95913: Update what's new in 3.11 for asyncio (#97806)
Co-authored-by: Kumar Aditya <59607654+kumaraditya303@users.noreply.github.com>
Co-authored-by: C.A.M. Gerlach <CAM.Gerlach@Gerlach.CAM>
Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
2022-10-04 11:36:20 -07:00
Kumar Aditya 53503ff60e
GH-82604: fix docs about configuring selector (#97755) 2022-10-04 09:45:37 -07:00
Ben Faulhaber a120b9f25d
gh-97754: Update doc for default location of per-user installs on Windows (GH-97756) 2022-10-04 17:04:41 +01:00
Victor Stinner 6cbbc26a73
gh-97669: Remove outdated example scripts (#97675)
Remove outdated example scripts of the Tools/scripts/ directory. A
copy can be found in the old-demos project:
https://github.com/gvanrossum/old-demos

Removed scripts (39):

* byext.py
* byteyears.py
* cleanfuture.py
* copytime.py
* crlf.py
* db2pickle.py
* dutree.doc
* dutree.py
* find-uname.py
* find_recursionlimit.py
* finddiv.py
* findlinksto.py
* findnocoding.py
* fixcid.py
* fixdiv.py
* fixheader.py
* fixnotice.py
* fixps.py
* get-remote-certificate.py
* google.py
* highlight.py
* ifdef.py
* import_diagnostics.py
* lfcr.py
* linktree.py
* lll.py
* mailerdaemon.py
* make_ctype.py
* mkreal.py
* objgraph.py
* pdeps.py
* pickle2db.py
* pindent.py
* pysource.py
* reindent-rst.py
* rgrep.py
* suff.py
* texi2html.py
* which.py

Changes:

* Remove test_fixcid, test_lll, test_pdeps and test_pindent
  of test.test_tools.
* Remove get-remote-certificate.py changelog entry, since the script
  was removed.

Note: there is a copy of crlf.py in Lib/test/test_lib2to3/data/.
2022-10-04 10:49:00 +02:00
matheusja 49802605f8
gh-97709: Included newline separator in Mandelbrot set (#97737)
Included newline separator in Mandelbrot set

Now the Mandelbrot set one-liner example on separates the lines with a '\n' character.
2022-10-03 22:34:02 -07:00
Adam Turner 5e997cff3e
gh-93738: Documentation C syntax (:c:data:`0` -> ``0``) (#97771)
:c:data:`0` -> ``0``
2022-10-04 03:46:30 +02:00
Rohan Shah d053c47bfd
Minor grammar changes to http.client docs (#96221)
Minor grammar changes
2022-10-03 16:19:39 -07:00
Géry Ogam 0c91a12511
Update http.client.rst (#24803)
* Update http.client.rst

* Apply suggestions from code review

Co-authored-by: Éric <merwok@netwok.org>

* Update http.client.rst

Co-authored-by: Éric <merwok@netwok.org>
Co-authored-by: Senthil Kumaran <senthil@python.org>
2022-10-03 16:18:36 -07:00
Ivan Kapeykin d78aa4e11a
multiprocessing docs: Remove extra option ELLIPSIS from section with code (#96625) 2022-10-03 15:41:08 -07:00
Boris Verkhovskiy 0ea8b925d0
Document that MozillaCookieJar works for curl's cookie files (#91852)
MozillaCookieJar works for curl's cookies
2022-10-03 15:07:54 -07:00
Gregory P. Smith b0f89cb431
gh-96512: Move int_max_str_digits setting to PyConfig (#96944)
It had to live as a global outside of PyConfig for stable ABI reasons in
the pre-3.12 backports.

This removes the `_Py_global_config_int_max_str_digits` and gets rid of
the equivalent field in the internal `struct _is PyInterpreterState` as
code can just use the existing nested config struct within that.

Adds tests to verify unique settings and configs in subinterpreters.
2022-10-03 13:55:45 -07:00
Victor Stinner 64fe343717
gh-97681: Remove Tools/demo/ directory (#97682)
Remove the Tools/demo/ directory which contained old demo scripts. A
copy can be found in the old-demos project:
https://github.com/gvanrossum/old-demos

Remove the following old demo scripts:

* beer.py
* eiffel.py
* hanoi.py
* life.py
* markov.py
* mcast.py
* queens.py
* redemo.py
* rpython.py
* rpythond.py
* sortvisu.py
* spreadsheet.py
* vector.py

Changes:

* Remove a reference to the redemo.py script in the regex howto
  documentation.
* Remove a reference to the removed Tools/demo/ directory in the
  curses documentation.
* Update PC/layout/ to remove the reference to Tools/demo/ directory.
2022-10-03 17:09:02 +02:00
annonm e6f9ec5c03
Fix typo in unittest docs (#97742) 2022-10-03 06:35:40 -07:00
C.A.M. Gerlach e738b5190b
gh-95913: Fix PEP number in PEP 678 What's New ref label (#97739)
What's New: Fix PEP number in PEP 678 ref target label
2022-10-03 06:12:37 +02:00
C.A.M. Gerlach bd00112a99
gh-95913: Copyedit/improve New Modules What's New section (#97721)
* Link TOML & WSGI in New Modules section, refine text & add ref label

* Further reformat new modules & add PEP link to tomllib
2022-10-03 06:04:10 +02:00
C.A.M. Gerlach 9148c0d893
gh-97740: Fix bang in Sphinx C domain ref target syntax (#97741)
* gh-97740: Fix bang in Sphinx C domain ref target syntax

Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>

* Add NEWS entry for C domain bang fix

Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>
2022-10-03 05:51:22 +02:00
Kumar Aditya 9151bbefea
GH-85447: Clarify docs about awaiting future multiple times (#97738) 2022-10-02 15:16:51 -07:00
Vinay Sajip cac2e8a51f
[docs] Update logging cookbook with recipe for using a logger like an output… (GH-97730) 2022-10-02 14:26:14 +01:00
C.A.M. Gerlach e8165d47b8
gh-97607: Fix content parsing in the impl-detail reST directive (#97652)
* Don't parse content as arg in the impl-detail directive

This does not change the (untranslated) output,
but ensures that the doctree node metadata is correct.
which fixes gh-97607 with the text not being translated.
It also simplifies the code and logic
and makes it consistant with the docutils built-in directives.

* Remove unused branch from impl-detail directive handling no-content case

This is not used anywhere in the docs and lacks a clear use case,
and is more likely a mistake which is now flagged at build time.
This simplifies the logic from two code paths to one,
and makes the behavior consistant with similar built-in directives
(e.g. the various admonition types).

* Further simplify impl-detail reST directive code
2022-10-02 07:20:17 +02:00
C.A.M. Gerlach dcc82331c8
gh-95975: Move except/*/finally ref labels to more precise locations (#95976)
* gh-95975: Move except/*/finally ref labels to more precise locations

* Add section headers to fix :keyword: role and aid navigation

* Move see also to the introduction rather than a particular subsection

* Fix other minor Sphinx syntax issues with except

Co-authored-by: Ezio Melotti <ezio.melotti@gmail.com>

* Suppress redundant link to same section for except too

* Don't link try/except/else/finally keywords if in the same section

* Format try/except/finally as keywords in modified sections

Co-authored-by: Ezio Melotti <ezio.melotti@gmail.com>
2022-10-02 07:12:56 +02:00
Gregory P. Smith 8baef8ae36
gh-95588: Drop the safety claim from `ast.literal_eval` docs. (#95919)
It was never really safe and this claim conflicts directly with the big warning in the docs about it being able to crash the interpreter.
2022-10-01 17:55:40 -07:00
Will Hawkins bd7d0e875e
Fix capitalization of Unix in documentation (#96913) 2022-10-01 16:41:06 -07:00
Łukasz Langa f00645d5db
gh-90908: Document asyncio.Task.cancelling() and asyncio.Task.uncancel() (#95253)
Co-authored-by: Thomas Grainger <tagrain@gmail.com>
2022-10-01 10:42:36 -07:00
Gregory P. Smith b05dd79649
gh-87597: Document TimeoutExpired.stdout & .stderr types (#97685)
This documents the behavior that has always been the case since timeout
support was introduced in Python 3.3.
2022-09-30 10:45:47 -07:00
Eddie Hebert 86a3be207d
Use SyntaxError invalid range in tutorial introduction example (GH-93031)
Use output from a 3.10+ REPL, showing invalid range, for the
SyntaxError examples in the tutorial introduction page.

Automerge-Triggered-By: GH:iritkatriel
2022-09-30 01:59:46 -07:00
Ofey Chan 83a3de4e06
gh-96348: Deprecate the 3-arg signature of coroutine.throw and generator.throw (GH-96428) 2022-09-30 09:43:02 +01:00
Jeff Allen 9a11ed8e50
gh-96397: Document that attributes need not be identifiers (#96454)
Co-authored-by: C.A.M. Gerlach <CAM.Gerlach@Gerlach.CAM>
2022-09-29 16:02:27 -07:00
NoSuck 0179a82caa
closes gh-97650: correct sphinx executable (gh-97651) 2022-09-29 15:53:41 -07:00
Stanley c759944f16
gh-52597: Add position-only markers for os functions (#94735) 2022-09-28 18:06:50 -07:00
Kumar Aditya 575a253b5c
GH-82448: Add thread timeout for loop.shutdown_default_executor (#97561)
Co-authored-by: Kyle Stanley <aeros167@gmail.com>
2022-09-28 10:39:42 -07:00
Kumar Aditya 9a404b173e
fixup policy docs (#97618) 2022-09-28 10:34:49 -07:00
Vinay Sajip 5c110d1126
gh-65046: Add note about logging from async code. (GH-97602) 2022-09-28 05:17:42 +01:00
Andrew Kay d582edf0be
Fix docs on conditional expression grouping (GH-96447) 2022-09-27 21:57:32 -05:00
C.A.M. Gerlach cc0f3a10f0
gh-96377: Update asyncio policy doc intro paras to be clear and accurate (#97603)
Also fix up some cross-references in the asyncio docs.
2022-09-27 16:47:14 -07:00
Pablo Galindo Salgado aab01e3524
gh-96670: Raise SyntaxError when parsing NULL bytes (#97594) 2022-09-27 23:23:42 +01:00
Serhiy Storchaka dd53b79de0
gh-96959: Update more HTTP links (GH-97536)
Use HTTPS for documents which are available by both HTTP and HTTPS
links, but there is no redirection from HTTP to HTTPS or vice versa.
2022-09-27 14:08:11 +03:00
Kumar Aditya d68c37c0d0
GH-65046: Fix docs about logging in `asyncio` (#97559)
Explain that logging should not use network I/O.
2022-09-26 15:27:15 -07:00
Stanley 2b428a1fae
gh-82530: Create blank function instead of invalid import for email example (#97529)
Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2022-09-26 00:06:11 -04:00
Serhiy Storchaka db39050396
gh-96959: Update HTTP links which are redirected to HTTPS (GH-96961) 2022-09-24 14:38:53 +03:00
Steve Dower a4ac14faa5
gh-77171: Fixes SubFormat check to compare the entire value. Add docs (GH-97509) 2022-09-23 16:08:21 +01:00
Stanley 80bc7d7c0a
gh-75608: Add Windows FAQ entry for missing UCRT (GH-92765) 2022-09-23 11:44:01 +01:00
Jeff Allen 9d432b4a18
gh-96397: Document that keywords in calls need not be identifiers (#96393)
This represents the official SC stance, see
https://github.com/python/steering-council/issues/142#issuecomment-1252172695
2022-09-22 11:10:15 -07:00
Harry ec403536f1
include OrderedDict import in TimeBoundedLRU example (GH-96962) 2022-09-22 10:58:19 -05:00
partev b4f5f07d07
Doc: fix link redirect (GH-96606)
"Hyperbolic_function" -> "Hyperbolic_functions"
2022-09-21 21:47:46 +02:00
Stanley 4b81139aac
gh-81039: Add small example of f-string's "=}" to tutorial (gh-92291) 2022-09-21 08:57:03 -04:00
Stanley e5ab0b6aa6
gh-71141: Add note on rejecting "leading-dot" syntax for with statements (#96928)
Co-authored-by: Daniël van Noord <13665637+DanielNoord@users.noreply.github.com>
2022-09-20 21:16:39 -07:00
Vinay Sajip 6ad47b41a6
gh-96727: Document restrictions on Handler.emit() with respect to locking. (GH-96948) 2022-09-20 09:40:06 +01:00