summaryrefslogtreecommitdiffstats
path: root/Doc/tutorial
Commit message (Collapse)AuthorAgeFilesLines
* [3.12] gh-101100: Fix Sphinx warnings about list methods (GH-127054) (#127512)Miss Islington (bot)2024-12-021-5/+5
| | | | Co-authored-by: Yuki Kobayashi <drsuaimqjgar@gmail.com>
* [3.12] gh-127265: Remove single quotes from 'arrow's in tutorial/errors.rst ↵Miss Islington (bot)2024-11-251-1/+1
| | | | | | | (GH-127268) (cherry picked from commit 26ff32b30553e1f7b0cc822835ad2da8890c180c) Co-authored-by: funkyrailroad <funkyrailroad@users.noreply.github.com>
* [3.12] Docs: make a tutorial example more precise (GH-125066) (GH-125079)Miss Islington (bot)2024-11-011-11/+9
| | | | | | | | | | | | Docs: make a tutorial example more precise (GH-125066) Based on discussion here: (cherry picked from commit 6e3c70c61bf961e55e9912a31ca11f61c8e2cd0c) https: //discuss.python.org/t/omission-in-the-documentation/66816 Co-authored-by: Ned Batchelder <ned@nedbatchelder.com>
* [3.12] Prefer "similar" over "equivalent" in tutorial (GH-125343) (GH-125373)Miss Islington (bot)2024-10-301-4/+4
| | | | | | | | | | | | | | | | Prefer "similar" over "equivalent" in tutorial (GH-125343) In the datastructures tutorial doc, some operations are described as "equivalent to" others. This has led to some user-confusion -- at least in the Discourse forums -- about cases in which the operations differ. This change doesn't systematically eliminate the word "equivalent" from the tutorial. It just substitutes "similar to" in several cases in which "equivalent to" could mislead users into expecting exact equivalence. (cherry picked from commit 4a2282b0679bbf7b7fbd36aae1b1565145238961) Co-authored-by: Stephen Rosen <sirosen@globus.org>
* [3.12] gh-85583: Add f-string index in tutorial/inputoutput.rst (GH-21681) ↵Miss Islington (bot)2024-10-301-0/+7
| | | | | | | | | | | | | | | | | | | (GH-126192) gh-85583: Add f-string index in tutorial/inputoutput.rst (GH-21681) * bpo-41411 fstring index in tutorial/inputoutput To assist in searching for fstrings I have added an index * Add newline --------- (cherry picked from commit a3443c0e22a8623afe4c0518433b28afbc3a6df6) Co-authored-by: amaajemyfren <32741226+amaajemyfren@users.noreply.github.com> Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com> Co-authored-by: Carol Willing <carolcode@willingconsulting.com>
* [3.12] docs: restore an anchor to for/else (GH-126154) (#126158)Miss Islington (bot)2024-10-301-0/+1
| | | | | | docs: restore an anchor to for/else (GH-126154) (cherry picked from commit 2d9d10179ff3f13029bf4430e62c455a839987ca) Co-authored-by: Ned Batchelder <ned@nedbatchelder.com>
* [3.12] gh-125383: Update `fib` function comment for accuracy (GH-125386) ↵Miss Islington (bot)2024-10-131-2/+2
| | | | | | | | | | (#125396) gh-125383: Update `fib` function comment for accuracy (GH-125386) `Doc/tutorial/controlflow.rst`: fix comment for `fib` function (cherry picked from commit 283ea5f3b2b6a18605b8598a979afe263b0f21ce) Co-authored-by: Wulian <xiguawulian@gmail.com>
* [3.12] Doc: Fix a typo in "Function Examples" in the control-flow tutorial ↵Miss Islington (bot)2024-10-121-1/+1
| | | | | | | | (GH-125338) (#125342) Doc: Fix a typo in "Function Examples" in the control-flow tutorial (GH-125338) (cherry picked from commit 5a074aab845f82f4a150c27b905dae05c337d381) Co-authored-by: Rafael Fontenelle <rffontenelle@users.noreply.github.com>
* [3.12] gh-101100: Consolidate documentation on `ModuleType` attributes ↵Alex Waygood2024-10-091-2/+3
| | | | | | | | (#124709) (#125211) Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com> Co-authored-by: Barry Warsaw <barry@python.org> Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
* [3.12] Docs: for for/else clarify that return or raise also skip the else ↵Miss Islington (bot)2024-09-301-2/+4
| | | | | | | | | | (GH-124591) (#124660) Docs: for for/else clarify that return or raise also skip the else (GH-124591) (cherry picked from commit 5329d1b74a86b3a22ff36f7976bfe720ee06d10d) Co-authored-by: Ned Batchelder <ned@nedbatchelder.com> Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
* [3.12] For-else deserves its own section in the tutorial (GH-123946) (#124563)Miss Islington (bot)2024-09-261-31/+54
| | | | | | (cherry picked from commit ffdc80e93d9d947531fa0123e5b392c6f1fd9136) Co-authored-by: Ned Batchelder <ned@nedbatchelder.com> Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
* [3.12] gh-101100: Add a table of class attributes to the "Custom classes" ↵Alex Waygood2024-09-251-3/+3
| | | | section of the data model docs (#124480) (#124558)
* [3.12] gh-123492: Remove unnecessary `:func:` parentheses (gh-123493) (#123512)Wei-Hsiang (Matt) Wang2024-08-301-1/+1
|
* [3.12] gh-122944: Fix incorrect prompt strings in the Python Tutorial ↵Miss Islington (bot)2024-08-124-10/+10
| | | | | | | | | | | (GH-122949) (#122955) gh-122944: Fix incorrect prompt strings in the Python Tutorial (GH-122949) In the REPL, top level comments are followed by a primary, not secondary prompt. Fix the places in the in the tutorial that use the latter. (cherry picked from commit be90648fb2de58b148dcc7553a08ca646911baf2) Co-authored-by: Damien <81557462+Damien-Chen@users.noreply.github.com>
* [3.12] gh-121905: Consistently use "floating-point" instead of "floating ↵Serhiy Storchaka2024-07-194-9/+9
| | | | | point" (GH-121907) (GH-122013) (cherry picked from commit 1a0c7b9ba48a2dffb70bb0c7327abae1d3e87356)
* [3.12] gh-120452: improve documentation about private name mangling ↵Miss Islington (bot)2024-07-131-0/+5
| | | | | | | | | (GH-120451) (#121716) gh-120452: improve documentation about private name mangling (GH-120451) (cherry picked from commit f4d6e45c1e7161878b36ef9e876ca3e44b80a97d) Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com> Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
* [3.12] gh-120345: Fix incorrect use of the :class: role with the "()" suffix ↵Miss Islington (bot)2024-06-121-2/+2
| | | | | | | | | | (GH-120347) (GH-120412) * Remove "()" when refer to a class as a type. * Use :func: when refer to a callable. * Fix reference to the datetime.astimezone() method. (cherry picked from commit 92c9c6ae147e1e658bbc8d454f8c7b2c4dea31d1) Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
* [3.12] gh-110383: Improve 'old string formatting' text in tutorial ↵Miss Islington (bot)2024-06-071-3/+5
| | | | | | | (GH-120219) (#120230) (cherry picked from commit 225aab7f70d804174cc3a75bc04a5bb1545e5adb) Co-authored-by: Erlend E. Aasland <erlend@python.org>
* [3.12] gh-119016: Remove outdated sentences from the "classes" tutorial ↵Miss Islington (bot)2024-06-011-5/+1
| | | | | | | (GH-119130) (#119926) Co-authored-by: Nice Zombies <nineteendo19d0@gmail.com> Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
* [3.12] docs: fix a few typos identified by codespell (GH-119516) (#119571)Hugo van Kemenade2024-05-261-1/+1
| | | | Co-authored-by: Ned Batchelder <ned@nedbatchelder.com>
* [3.12] GH-110383: Improve Tutorial for Input Ouput (GH-119230) (GH-119327)Miss Islington (bot)2024-05-211-4/+16
| | | | | | | | GH-110383: Improve Tutorial for Input Ouput (GH-119230) (cherry picked from commit 9db2fd7edaa9d03e8c649c3bb0e8d963233cde22) Co-authored-by: Blaise Pabon <blaise@gmail.com> Co-authored-by: edson duarte <eduarte.uatach@gmail.com>
* [3.12] gh-119078: Clarify venv tutorial (GH-119129) (GH-119141)Miss Islington (bot)2024-05-181-4/+4
| | | (cherry picked from commit 0f5e8bed636c2f29701e5a1965d1b088d33abbf0)
* [3.12] Format None, True, False and NotImplemented as literals (GH-118758) ↵Serhiy Storchaka2024-05-081-1/+1
| | | | | (GH-118794) (cherry picked from commit 05c2fe1acda9ea5a57061642c36e8b73bb4fbba4)
* [3.12] Remove Python 3.5 hardcoded version in the tutorial appendix ↵Miss Islington (bot)2024-05-071-2/+2
| | | | | | | | (GH-117612) (GH-118707) Remove Python 3.5 hardcoded version in the tutorial appendix (GH-117612) (cherry picked from commit a855f824a2f5a310ffa58a973a8fe9feaa2500b3) Co-authored-by: Kerim Kabirov <the.privat33r+gh@pm.me>
* [3.12] Add 'The Python 2.3 Method Resolution Order' (GH-116435) (#117885)Hugo van Kemenade2024-04-151-1/+1
| | | | Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com>
* [3.12] gh-117597: Clarify exception handling in the tutorial (GH-117681) ↵Miss Islington (bot)2024-04-091-3/+3
| | | | | | | (#117700) (cherry picked from commit a05068db0cb43337d20a936d919b9d88c35d9818) Co-authored-by: Nice Zombies <nineteendo19d0@gmail.com>
* [3.12] gh-116563: Update tutorial error example (GH-116569) (#116624)Miss Islington (bot)2024-03-111-4/+4
| | | | | | | | There now may be multiple carets pointing at a token rather than just a character. Fix the sentence about possible causes. (cherry picked from commit 3e45030076bf2cfab41c4456c73fb212b7322c60) Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
* [3.12] GH-116271 Docs: provide clarification for object assignments in the ↵Miss Islington (bot)2024-03-041-7/+24
| | | | | | | | Tutorial section (GH-116283) (#116305) Co-authored-by: Kerim Kabirov <39376984+Privat33r-dev@users.noreply.github.com> Co-authored-by: Ned Batchelder <ned@nedbatchelder.com> Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com>
* [3.12] gh-114648: Add IndexError exception to tutorial datastructures ↵Miss Islington (bot)2024-02-011-4/+3
| | | | | | | | list.pop entry (GH-114681) (#114841) Remove redundant explanation of optional argument. (cherry picked from commit 57c3e775df5a5ca0982adf15010ed80a158b1b80) Co-authored-by: srinivasan <shivnaren@gmail.com>
* [3.12] gh-114069: Revise Tutorial Methods paragraph (GH-114127) (#114131)Miss Islington (bot)2024-01-161-6/+5
| | | | | | | | gh-114069: Revise Tutorial Methods paragraph (GH-114127) Remove excess words in the first and third sentences. (cherry picked from commit 31a2543c80e1e38c97e50533249d9aa00e2f6cae) Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
* [3.12] Tutorial: Clarify 'nonzero exit status' in the appendix (GH-112039) ↵Miss Islington (bot)2024-01-121-1/+1
| | | | | | | | (#113999) Tutorial: Clarify 'nonzero exit status' in the appendix (GH-112039) (cherry picked from commit 32f3684b8f18d757945eee67a697cb4a95c697db) Co-authored-by: Andrew Zipperer <47086307+zipperer@users.noreply.github.com>
* [3.12] gh-113208: Mention namespace packages don't require __init__.py ↵Miss Islington (bot)2023-12-191-1/+2
| | | | | | | (GH-113209) (#113276) Co-authored-by: Unique-Usman <86585626+Unique-Usman@users.noreply.github.com> Co-authored-by: C.A.M. Gerlach <CAM.Gerlach@Gerlach.CAM>
* [3.12] gh-113113: doc: use less ambiguously named variable (gh-113114) ↵Miss Islington (bot)2023-12-141-3/+3
| | | | (gh-113122)
* [3.12] gh-101100: Improve documentation for attributes on instance methods ↵Miss Islington (bot)2023-12-081-2/+4
| | | | | | | | (GH-112832) (#112872) gh-101100: Improve documentation for attributes on instance methods (GH-112832) (cherry picked from commit ed21d0c1f4bd17b392e24bfd83e652723dad4ddf) Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
* [3.12] Fix link to 'The Perils of Floating Point', on the tutorial ↵Miss Islington (bot)2023-12-031-1/+1
| | | | | | | | (GH-112499) (GH-112664) Use author link to 'The Perils of Floating Point'. (cherry picked from commit c27b09c81368bc3b756e94a79a39307ce44a4a2c) Co-authored-by: Marco Aurélio A. Barbosa <aureliobarbosa@gmail.com>
* [3.12] gh-110383: Explained which error message is generated when there is ↵Miss Islington (bot)2023-11-191-2/+1
| | | | | | | an unhandled exception (GH-111574) (#112264) Co-authored-by: Unique-Usman <86585626+Unique-Usman@users.noreply.github.com> Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com>
* [3.12] gh-111406: Fix broken link to bpython's site (GH-111407) (#111408)Miss Islington (bot)2023-10-271-1/+1
| | | | | | gh-111406: Fix broken link to bpython's site (GH-111407) (cherry picked from commit 8a158a753c48d166ebceae0687e88ae0c0725c02) Co-authored-by: Zack Cerza <zack@cerza.org>
* [3.12] gh-101100: Fix Sphinx warning in `tutorial/introduction.rst` ↵Miss Islington (bot)2023-10-221-1/+1
| | | | | | | | (GH-111173) (#111175) gh-101100: Fix Sphinx warning in `tutorial/introduction.rst` (GH-111173) (cherry picked from commit 663cf513b0e973ab7aa4a8609d6616ad2c283f22) Co-authored-by: Maciej Olko <maciej.olko@affirm.com>
* [3.12] gh-110534 fix a URL redirect to wikipedia article on Fibonacci ↵Miss Islington (bot)2023-10-091-1/+1
| | | | | | | | numbers (GH-110535) (#110536) gh-110534 fix a URL redirect to wikipedia article on Fibonacci numbers (GH-110535) (cherry picked from commit 892ee72b3622de30acd12576b59259fc69e2e40a) Co-authored-by: partev <petrosyan@gmail.com>
* [3.12] Update floatingpoint.rst (GH-110509) (#110513)Miss Islington (bot)2023-10-081-1/+1
| | | | | | | | | | | | | | | | Update floatingpoint.rst (GH-110509) This commit removes a ':'. I believe the extra colon causes a display error. What I believe to be an error: Above this expression `round(math.pi, ndigits=2) == round(22 / 7, ndigits=2)` the page displays `.. doctest::`. What I observed: After I remove the extra colon, the page does not display `.. doctest::` (cherry picked from commit 8e56d551ceef37a307280bcc5303bf69ccc9f9c1) Co-authored-by: zipperer <47086307+zipperer@users.noreply.github.com>
* [3.12] gh-101100: Fix Sphinx warnings in `tutorial/controlflow.rst` ↵Miss Islington (bot)2023-09-291-2/+2
| | | | | | | | | (GH-109424) (#110084) gh-101100: Fix Sphinx warnings in `tutorial/controlflow.rst` (GH-109424) (cherry picked from commit 8898a8683b5631c24d51a6a7babf55a255874950) Co-authored-by: Maciej Olko <maciej.olko@affirm.com> Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>
* [3.12] gh-101100: Fix sphinx warnings in `tutorial/appendix.rst` (GH-108750) ↵Hugo van Kemenade2023-09-021-4/+4
| | | | | | | | (#108759) (cherry picked from commit 3047f09490ae63f25d57efe1d14a9a65d9b5f6db) Co-authored-by: Nikita Sobolev <mail@sobolevn.me>
* [3.12] gh-101100: Fix sphinx warnings in `tutorial/classes.rst` (GH-108746) ↵Miss Islington (bot)2023-09-011-1/+1
| | | | | | | | (#108756) gh-101100: Fix sphinx warnings in `tutorial/classes.rst` (GH-108746) (cherry picked from commit e775601ef1ada83a80e1539d0bcd5509deadee14) Co-authored-by: Nikita Sobolev <mail@sobolevn.me>
* [3.12] Improve references in the tutorial (GH-108069) (#108203)Miss Islington (bot)2023-08-215-47/+48
| | | | | | | | | | Improve references in the tutorial (GH-108069) * Use full qualified names for references (even if they do not work now, they will work in future). * Silence references to examples. (cherry picked from commit 622ddc41674c2566062af82f7b079aa01d2aae8c) Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
* [3.12] GH-107987: Remove the Distributing Python Modules guide (GH-108016) ↵Miss Islington (bot)2023-08-171-1/+3
| | | | | | | | (#108081) GH-107987: Remove the Distributing Python Modules guide (GH-108016) (cherry picked from commit 33e6e3fec02ff3035dec52692542d3dd10124bef) Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>
* [3.12] gh-101100: Sphinx warnings: pick the low hanging fruits (GH-107386) ↵Serhiy Storchaka2023-07-292-3/+3
| | | | | (GH-107419) (cherry picked from commit f2d07d3289947d10b065b2bb7670c8fb6b6582f2)
* [3.12] gh-107017: Change Chapter Strings to Texts in the Introduction ↵Miss Islington (bot)2023-07-241-20/+20
| | | | | | | chapter. (GH-107104) (#107167) Co-authored-by: TommyUnreal <45427816+TommyUnreal@users.noreply.github.com> Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com>
* [3.12] gh-107017: Analolgy to Pascal and C replaced. (GH-107025) (#107124)Miss Islington (bot)2023-07-231-2/+2
| | | | | | (cherry picked from commit e59da0c4f283b966ccb175fb94460f58211a9704) Co-authored-by: TommyUnreal <45427816+TommyUnreal@users.noreply.github.com> Co-authored-by: Shantanu <12621235+hauntsaninja@users.noreply.github.com>
* [3.12] gh-107017: removed mention that C does it the same way (GH-107020) ↵Miss Islington (bot)2023-07-231-8/+15
| | | | | | (#107097) Co-authored-by: Jakub Červinka <cervinka.jakub.1989@gmail.com>
* [3.12] gh-71261: Add paragraph on shadowing submodules with star imports ↵Miss Islington (bot)2023-07-231-0/+16
| | | | | | (GH-107004) (#107100) Co-authored-by: wulmer <wulmer@users.noreply.github.com>