summaryrefslogtreecommitdiffstats
path: root/Doc/reference
Commit message (Collapse)AuthorAgeFilesLines
* [3.11] Docs: Fix backtick errors found by sphinx-lint (GH-97998) (#98371)C.A.M. Gerlach2022-10-223-10/+2
| | | | | | | | | Co-authored-by: Ezio Melotti <ezio.melotti@gmail.com>. (cherry picked from commit fa2d43e5184f5eaf3391844ec2400342a1b2ead4) Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com> Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com>
* gh-96397: Document that keywords in calls need not be identifiers (GH-96393)Miss Islington (bot)2022-10-221-2/+12
| | | | | | | This represents the official SC stance, see https://github.com/python/steering-council/issues/142GH-issuecomment-1252172695 (cherry picked from commit 9d432b4a181cd42017699de4354e7b36c5b87d88) Co-authored-by: Jeff Allen <ja.py@farowl.co.uk>
* Fix docs on conditional expression grouping (GH-96447) (GH-97606)Miss Islington (bot)2022-10-221-1/+1
|
* gh-95975: Move except/*/finally ref labels to more precise locations (GH-95976)Miss Islington (bot)2022-10-221-46/+76
| | | | | | | | | | | | | | | | | | | | | | * 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> (cherry picked from commit dcc82331c8f05a6a149ac15c519d4fbae72692b2) Co-authored-by: C.A.M. Gerlach <CAM.Gerlach@Gerlach.CAM>
* [3.11] gh-93738: Documentation C syntax (:c:type:<C type> -> :c:expr:<C ↵Łukasz Langa2022-10-221-1/+1
| | | | | | | | | | type>) (GH-97768) (#97924) :c:type:`<C type>` -> :c:expr:`<C type>` Co-authored-by: Łukasz Langa <lukasz@langa.pl> (cherry picked from commit 0031e62973801d34a9e19ab7bb199e9668e32d7b) Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>
* gh-86482: Document assignment expression need for ()s (GH-23291)Miss Islington (bot)2022-10-221-0/+7
| | | | | | Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com> (cherry picked from commit 2b5f1360ead9aa72ae00de59edfd6c229d13933f) Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
* [3.11] gh-97850: Remove the open issues section from the import reference ↵Miss Islington (bot)2022-10-221-19/+0
| | | | | | | | | | | | | (GH-97935) (GH-97994) Remove the open issues section from the import reference Tracking in https://github.com/python/cpython/issues/97850 instead. (cherry picked from commit f8edc6ff531bb98858185857513371f14519ed1d) Co-authored-by: Brett Cannon <brett@python.org> Automerge-Triggered-By: GH:brettcannon
* gh-97913 Docs: Add walrus operator to the index (GH-97921)Miss Islington (bot)2022-10-221-0/+6
| | | | | | | | | | | | | | | | | * 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> (cherry picked from commit 296313002fde56f52d6c81f17d7ba5c2eb57d098) Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com>
* gh-98172: Fix formatting in `except*` docs (GH-98173)Miss Islington (bot)2022-10-221-9/+9
| | | | | | (cherry picked from commit 5ecf961640192a2192383aa20e1e93dcdf23c9b6) Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
* gh-98227: executionmodel.rst: except* can also bind names (GH-98256)Miss Islington (bot)2022-10-221-1/+1
| | | | | | Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com> (cherry picked from commit 146f168fbf5b239158922f4defd494088c381525) Co-authored-by: BiscuitCandy <70342294+BiscuitCandy@users.noreply.github.com>
* GH-96359: Fix docs that claim int(0|1) doesn't match False (GH-96361)Miss Islington (bot)2022-08-291-1/+1
| | | | | (cherry picked from commit 3d3a86ed40626471b2c9e7f1336b228eb0dd0879) Co-authored-by: Jonathan Oberländer <github@l3vi.de>
* gh-95994: Clarify escaped newlines. (GH-96066)Miss Islington (bot)2022-08-261-11/+22
| | | | | | | | | | | | | | | | * gh-95994: clarify escaped newlines. * Rephrase ambiguous sentence. Co-authored-by: C.A.M. Gerlach <CAM.Gerlach@Gerlach.CAM> * Use `<newline>` in escape sequences table. Co-authored-by: C.A.M. Gerlach <CAM.Gerlach@Gerlach.CAM> Co-authored-by: C.A.M. Gerlach <CAM.Gerlach@Gerlach.CAM> (cherry picked from commit c3d591fd0699605c8253beda2372114052a7bdba) Co-authored-by: Ezio Melotti <ezio.melotti@gmail.com>
* [3.11] gh-91838: Use HTTPS links in docs for resources which redirect to ↵Serhiy Storchaka2022-08-041-3/+3
| | | | | | | | | | | | HTTPS (GH-95527) (GH-95643) If an HTTP link is redirected to a same looking HTTPS link, the latter can be used directly without changes in readability and behavior. It protects from a men-in-the-middle attack. This change does not affect Python examples.. (cherry picked from commit f79547a429d5c90af83a0da821e082cba20d4712) Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
* Fix async method reference links in `compound_stmts` docs (GH-94935)Miss Islington (bot)2022-07-221-2/+2
| | | | | (cherry picked from commit 79d2f549adcbbefd4f2c0a0c9dd572bbbf252c62) Co-authored-by: July Tikhonov <july.tikh@gmail.com>
* gh-91181: drop support for bytes on sys.path (GH-31934)Miss Islington (bot)2022-07-171-4/+2
| | | | | | | | | Support for bytes broke sometime between Python 3.2 and 3.6 and has been broken ever since. Trying to bring back supports is surprisingly difficult in the face of -b and checking for keys in sys.path_importer_cache. Since the support was broken for so long, trying to overcome the difficulty of bringing back the support has been deemed not worth it. Co-authored-by: Eryk Sun <eryksun@gmail.com> Co-authored-by: Brett Cannon <brett@python.org> (cherry picked from commit 6da988a46c8955755624ad9878288d5214fceb4e) Co-authored-by: Thomas Grainger <tagrain@gmail.com>
* Docs: remove redundant "adverb-adjective" hyphens from compound modifiers ↵Miss Islington (bot)2022-07-053-4/+4
| | | | | | | | (GH-94551) (GH-94557) Discussion: https://discuss.python.org/t/slight-grammar-fix-throughout-adverbs-dont-need-hyphen/17021 (cherry picked from commit 3440d197a55800ecceea3e115e44b4262411359c) Co-authored-by: Ned Batchelder <ned@nedbatchelder.com>
* [3.11] gh-93675: Fix typos in `Doc/` (GH-93676) (GH-94079)Łukasz Langa2022-06-211-1/+1
| | | | | | Closes GH-93675 (cherry picked from commit 830513754d081619b2d72db17770627312072fa5) Co-authored-by: luzpaz <luzpaz@users.noreply.github.com>
* bpo-45393: help() on operator precedence has misleading entries (GH-31246) ↵Miss Islington (bot)2022-05-191-2/+2
| | | | | | | (GH-92965) (cherry picked from commit fb082c2fc5a925085b179e63ca10b7f60b356d2f) Co-authored-by: Zackery Spytz <zspytz@gmail.com>
* gh-87304: Improve comments in language reference for imports (#92164)Robert Yang2022-05-031-3/+3
|
* gh-81548: Deprecate octal escape sequences with value larger than 0o377 ↵Serhiy Storchaka2022-04-301-0/+5
| | | | (GH-91668)
* bpo-21761: Clarify __file__/__cached__ in import reference (GH-31565)slateny2022-04-261-4/+5
| | | Automerge-Triggered-By: GH:brettcannon
* gh-89885: Improve import example in language reference (#91523)slateny2022-04-171-6/+4
| | | Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
* Language reference: Remove duplicated text about iterable unpacking (GH-25212)Jiashuo Li2022-04-031-3/+1
|
* bpo-46033: Clarify for-statement execution (GH-30025)Michał D2022-04-031-11/+8
| | | | Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu> Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
* bpo-24563: Link encoding names to encoding declarations (GH-32274)Terry Jan Reedy2022-04-031-3/+2
|
* bpo-14911: Corrected generator.throw() documentation (GH-32207)Dave Goncalves2022-03-312-3/+17
| | | Co-authored-by: Andrew Svetlov <andrew.svetlov@gmail.com>
* bpo-12029: [doc] clarify that except does not match virtual subclasses of ↵Irit Katriel2022-03-212-5/+7
| | | | the specified exception type (GH-32027)
* bpo-46013: Fix confusing kerning on period in docs (GH-29989)jmcb2022-03-201-1/+1
|
* Removed confusing reference to sys (GH-31638)David Gilbertson2022-03-081-3/+3
|
* Removed ambiguity in __init_subclass__ docs (GH-31540)David Gilbertson2022-03-081-1/+1
|
* bpo-45680: Improve docs on subscriptions w.r.t. `GenericAlias` objects ↵Alex Waygood2022-03-081-20/+30
| | | | (GH-29479)
* bpo-46725: Document starred expressions in for statements (GH-31481)Pablo Galindo Salgado2022-02-221-8/+13
| | | Automerge-Triggered-By: GH:pablogsal
* bpo-44977: Deprecate delegation of int to __trunc__ (GH-31031)Zackery Spytz2022-02-031-0/+3
| | | | | Calling int(a) when type(a) implements __trunc__ but not __int__ or __index__ now raises a DeprecationWarning.
* bpo-23556: [doc] Fix inaccuracy in documentation for raise without args. ↵Kinshuk Dua2022-01-271-8/+10
| | | | Improve tests for context in nested except handlers. (GH-29236)
* [doc]: Spotted errors while working on rstlint. (GH-30879)Julien Palard2022-01-271-1/+1
| | | | Also ignored some `make suspicious` false positives while assuring true positives were properly seen by rstlint.
* bpo-24650: Use full term "generator function" in yield expressions docs ↵Jacob Walls2022-01-071-2/+2
| | | | (GH-24663)
* bpo-45292: [PEP-654] exception groups and except* documentation (GH-30158)Irit Katriel2022-01-061-1/+47
|
* bpo-46095: Improve SeqIter documentation. (GH-30316)Raymond Hettinger2022-01-011-21/+0
|
* bpo-46076: Improve documentation for per-attribute docstrings with ↵Alex Waygood2021-12-191-3/+6
| | | | `__slots__` (GH-30109)
* Fix some false positives of documentation syntax problemsPablo Galindo2021-12-081-1/+1
|
* bpo-20751: Match variable name to the example. (GH-29980)Raymond Hettinger2021-12-081-4/+8
|
* bpo-45840: Improve cross-references in the data model documentation (GH-29633)Alex Waygood2021-12-051-54/+76
|
* bpo-20751: Replace method example with attribute example, matching the ↵Raymond Hettinger2021-12-041-4/+32
| | | | descriptor howto (GH-29909)
* bpo-45711: Change exc_info related APIs to derive type and traceback from ↵Irit Katriel2021-11-301-0/+6
| | | | the exception instance (GH-29780)
* bpo-45619: documentation of execution model: clarify and update binding ↵Arthur Milchior2021-11-261-9/+19
| | | | | | | | | | | summary (#29232) This does two changes that are quite related. 0. it add that variable binding can occur in pattern matching, an update of 3.10 which seems to have been omitted from the list of bindings 1. Given how long the sentence already was, with even subcases in the middle of the sentence, the commit breaks the sentence into an actual list.
* [doc] Clarify MRO precedence in descriptor super binding section (GH-29539)Jouke Witteveen2021-11-201-1/+1
| | | | A similar sentence is present in the 'Invocation from super' section of the descriptor HOWTO, where it is already correct.
* bpo-45250: fix docs regarding `__iter__` and iterators being inconsistently ↵Brett Cannon2021-11-201-14/+12
| | | | | required by CPython (GH-29170) It is now considered a historical accident that e.g. `for` loops and the `iter()` built-in function do not require the iterators they work with to define `__iter__`, only `__next__`.
* bpo-45640: [docs] Tokens are now clickable (GH-29260)Arthur Milchior2021-11-183-53/+53
| | | Co-authored-by: Łukasz Langa <lukasz@langa.pl>
* [doc] bpo-45680: Disambiguate ``__getitem__`` and ``__class_getitem__`` in ↵Alex Waygood2021-11-181-18/+146
| | | | | | | | | | | | | | the data model (GH-29389) The documentation explaining Python's data model does not adequately explain the differences between ``__getitem__`` and ``__class_getitem__``, nor does it explain when each is called. There is an attempt at explaining ``__class_getitem__`` in the documentation for ``GenericAlias`` objects, but this does not give sufficient clarity into how the method works. Moreover, it is the wrong place for that information to be found; the explanation of ``__class_getitem__`` should be in the documentation explaining the data model. This PR has been split off from GH-29335.
* [doc] minor fixes to expressions.rst (GH-29444)Ethan Furman2021-11-061-3/+3
|