-
-
Notifications
You must be signed in to change notification settings - Fork 31.9k
gh-123370: Fix the canvas not clearing after running turtledemo.clock #123457
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice. Needs one change and one question answered. I also need to verify that we can remove functions. I suggested other changes on issue for other PR/issue.
A Python core developer has requested some changes be made to your pull request before we can consider merging it. If you could please address their requests along with any other requests in other reviews from core developers that would be appreciated. Once you have made the requested changes, please leave a comment on this pull request containing the phrase |
I have made the requested changes; please review again bandicam.2024-09-01.19-56-12-916.mp4 |
Thanks for making the requested changes! @terryjreedy: please review the changes made to this pull request. |
Misc/NEWS.d/next/Library/2024-08-28-19-27-35.gh-issue-123370.SPZ9Ux.rst
Outdated
Show resolved
Hide resolved
A Python core developer has requested some changes be made to your pull request before we can consider merging it. If you could please address their requests along with any other requests in other reviews from core developers that would be appreciated. Once you have made the requested changes, please leave a comment on this pull request containing the phrase |
I have made the requested changes; please review again Thank you for your review again. In the previous clock.py, the parameters used in the calls to the functions https://github.com/python/cpython/blob/main/Lib/turtledemo/clock.py#L82-L93 https://github.com/python/cpython/blob/main/Lib/turtledemo/clock.py#L105-L105 Now wochentag and datum functions now ensure that the parameters and functionality are same (Because both use the datetime module) def wochentag(t):
return t.strftime(format="%A")
def datum(z):
return z.strftime(format="%Y/%m/%d") |
Thanks for making the requested changes! @terryjreedy: please review the changes made to this pull request. |
You reverted more than I requested, but moving the other changes, which I do want, to a separate cleanup/modernize backported PR is fine. |
Thanks @Wulian233 for the PR, and @terryjreedy for merging it 🌮🎉.. I'm working now to backport this PR to: 3.12. |
Thanks @Wulian233 for the PR, and @terryjreedy for merging it 🌮🎉.. I'm working now to backport this PR to: 3.13. |
Sorry, @Wulian233 and @terryjreedy, I could not cleanly backport this to
|
Sorry, @Wulian233 and @terryjreedy, I could not cleanly backport this to
|
…tledemo.clock (pythonGH-123457) Rewriting the day and date every tick somehow prevented them from being removed either by clicking STOP or loading another example. The solution is to rewrite them only when they change. (cherry picked from commit c124577) Co-authored-by: Wulian <[email protected]>
Merge conflict explained at #118673 (comment). This will impact (edit) docstring changes in the rest of turtledemo files. I have fixed this one for 3.13 and will backport that PR. |
GH-125653 is a backport of this pull request to the 3.13 branch. |
…o.clock (gh-123457) (#125653) [3.13] gh-123370: Fix the canvas not clearing after running turtledemo.clock (GH-123457) Rewriting the day and date every tick somehow prevented them from being removed either by clicking STOP or loading another example. The solution is to rewrite them only when they change. (cherry picked from commit c124577) Co-authored-by: Wulian <[email protected]>
…tledemo.clock (pythongh-123457) (pythonGH-125653) [3.13] pythongh-123370: Fix the canvas not clearing after running turtledemo.clock (pythonGH-123457) Rewriting the day and date every tick somehow prevented them from being removed either by clicking STOP or loading another example. The solution is to rewrite them only when they change. (cherry picked from commit c124577) (cherry picked from commit 30d7e9e) Co-authored-by: Terry Jan Reedy <[email protected]> Co-authored-by: Wulian <[email protected]>
…rtledemo.clock (gh-123457) (GH-125653) (#125656) Rewriting the day and date every tick somehow prevented them from being removed either by clicking STOP or loading another example. The solution is to rewrite them only when they change. (cherry picked from commit c124577) (cherry picked from commit 30d7e9e) Co-authored-by: Terry Jan Reedy <[email protected]> Co-authored-by: Wulian <[email protected]>
….clock (python#123457) Rewriting the day and date every tick somehow prevented them from being removed either by clicking STOP or loading another example. The solution is to rewrite them only when they change.
In addition to fixing this bug, I also made some changes.
coding: cp1252
, as this file has always been utf8.