Skip to content

Update turtledemo docstrings with correct file names #125665

Closed

Description

@Wulian233

Bug report

Bug description:

In #123370 , I discussed with Terry some measures to modernize the turtledemo. This requires changes to each file. First, I want to modify the incorrect comment file names, which is the easiest to review. There are five measures to modify, e.g German function names and parameter names, change ISO format time, and others focus on clock.py. I have already completed 2 in my initial commit in a0b922f , but I later reverted the changes due to backporting

From previous discussion:

I'd like to see a follow-up 'modernize PR to

Replace module docstring with "turtledemo/clock.py -- clock program showing time and date." File name is wrong and instruction only applies when run in turtledemo, which it is redundant.

(clock.py fixed)

This issue is a bug fix, not a modernization enhancement?

Linked PRs

Activity

  1. added
    stdlibStandard Library Python modules in the Lib/ directory
    on Oct 21, 2024
  2. changed the title [-]Replace turtledemo docstring with correct file name[/-] [+]Update turtledemo docstrings with correct file names[/+] on Oct 23, 2024
  3. added a commit that references this issue on Oct 23, 2024
  4. added a commit that references this issue on Jan 12, 2025
  5. merwok commented on May 3, 2025

    @merwok
    Member

    Can I ask why have the filename in the docstring at all?

    That’s not the recommended format for docstrings, and if it’s needed by the demo machinery or the tests, then it can be found from the file without having to be in the docstring.

  6. terryjreedy commented on May 3, 2025

    @terryjreedy
    Member

    The original author put them there and I did not consider removing them completely, as opposed to correcting and condensing the previous headers. When files are printed (less common now than it used to be), it is nice to have the filename printed. Since this might be more useful in classrooms where turtledemo is used than in professional settings, I am not inclinded to remove them.

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    stdlibStandard Library Python modules in the Lib/ directorytype-bugAn unexpected behavior, bug, or error

    Projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions