Skip to content

gh-157847: Re-write more of the turtle reference docs - #159685

Merged
StanFromIreland merged 2 commits into
python:mainfrom
StanFromIreland:turtle/another-round
Oct 20, 2026
Merged

StanFromIreland merged 2 commits into
python:mainfrom
StanFromIreland:turtle/another-round

Conversation

@StanFromIreland

Copy link
Copy Markdown
Member

No description provided.

@read-the-docs-community

read-the-docs-community Bot commented Oct 18, 2026 •

Copy link
Copy Markdown

@willingc willingc left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice cleanup @StanFromIreland. A few suggestions for readability for children and young adults. Fine to ship as is too.

Comment thread Doc/library/turtle.rst Outdated
Comment thread Doc/library/turtle.rst Outdated
Comment thread Doc/library/turtle.rst
Comment thread Lib/turtle.py Outdated
Comment thread Lib/turtle.py
9
"""
speeds = {'fastest':0, 'fast':10, 'normal':6, 'slow':3, 'slowest':1 }
speed_strings = {

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is there a reason to name it speed_strings vs. speeds?

@StanFromIreland StanFromIreland Oct 20, 2026 •

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I was going to tidy up the dictionary (since it was in a bit of a mess), and I decided to change to a more precise name while I was at it. As I mentioned on the other PRs, I'm not particularly worried about churn, most of these lines blame to the original import anyway.

@willingc willingc Oct 20, 2026 •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we do this... Add the word "descriptive" at the start of line 2219 so it reads "descriptive speed string" or alternatively "speed description string". speed_strings is a bit confusing for learners since it encodes type in the name of the dict.

If we describe a bit more precisely at line 2219, the example name makes more sense.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hmm, I think you may have been looking at an older commit? I adjusted it to:

You can also use these names instead of numbers:

Based on Maciej's suggestion.

Comment thread Lib/turtle.py Outdated
Comment thread Doc/library/turtle.rst
Comment thread Doc/library/turtle.rst Outdated
Comment thread Doc/library/turtle.rst Outdated
Comment thread Doc/library/turtle.rst Outdated
Comment thread Lib/turtle.py Outdated
Comment on lines +2179 to +2183
"""Pull the pen up.

Aliases: penup | pu | up

The turtle does not draw when it moves.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
"""Pull the pen up.
Aliases: penup | pu | up
The turtle does not draw when it moves.
"""Lift the pen. The turtle does not draw when it moves.
Aliases: penup | pu | up

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Applied the re-wording, but I kept the other sentence after the aliases.

@m-aciek m-aciek Oct 20, 2026 •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think they shouldn't be splitted. The effect should be an inherent part of the explanation.

Comment thread Lib/turtle.py Outdated
Co-authored-by: Maciej Olko <[email protected]>
Co-Authored-By: Carol Willing <[email protected]>
@StanFromIreland
StanFromIreland enabled auto-merge (squash) October 20, 2026 18:21
@StanFromIreland StanFromIreland added needs backport to 3.14 bugs and security fixes needs backport to 3.15 bugs and security fixes labels Oct 20, 2026
@StanFromIreland
StanFromIreland merged commit f071bac into python:main Oct 20, 2026
57 checks passed
@StanFromIreland
StanFromIreland deleted the turtle/another-round branch October 20, 2026 19:20
@github-project-automation github-project-automation Bot moved this from Todo to Done in Docs PRs Oct 20, 2026
@miss-islington-app

Copy link
Copy Markdown

Thanks @StanFromIreland for the PR 🌮🎉.. I'm working now to backport this PR to: 3.14, 3.15.
🐍🍒⛏🤖

@bedevere-app

bedevere-app Bot commented Oct 20, 2026

Copy link
Copy Markdown

GH-159948 is a backport of this pull request to the 3.15 branch.

@bedevere-app bedevere-app Bot removed the needs backport to 3.15 bugs and security fixes label Oct 20, 2026
@bedevere-app

bedevere-app Bot commented Oct 20, 2026

Copy link
Copy Markdown

GH-159949 is a backport of this pull request to the 3.14 branch.

@bedevere-app bedevere-app Bot removed the needs backport to 3.14 bugs and security fixes label Oct 20, 2026
JelleZijlstra pushed a commit that referenced this pull request Oct 21, 2026
…9685) (#159949)

gh-157847: Re-write more of the `turtle` reference docs (GH-159685)
(cherry picked from commit f071bac)

Co-authored-by: Stan Ulbrych <[email protected]>
Co-authored-by: Maciej Olko <[email protected]>
Co-authored-by: Carol Willing <[email protected]>
JelleZijlstra pushed a commit that referenced this pull request Oct 21, 2026
…9685) (#159948)

gh-157847: Re-write more of the `turtle` reference docs (GH-159685)
(cherry picked from commit f071bac)

Co-authored-by: Stan Ulbrych <[email protected]>
Co-authored-by: Maciej Olko <[email protected]>
Co-authored-by: Carol Willing <[email protected]>
@StanFromIreland

StanFromIreland commented Oct 21, 2026 •

Copy link
Copy Markdown
Member Author

Sorry @willingc and @m-aciek, I enabled auto-merge and it merged before I saw your comments (feel free to disable it in the future, Maciek, you have to close and reopen the PR IIRC).

I will address them in the next PR (as I still have a bit to do).

@willingc

Copy link
Copy Markdown
Contributor

No worries @StanFromIreland. It was a nit more than critical since I had already approved 😄

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

docs Documentation in the Doc dir skip issue skip news

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

3 participants