-
-
Notifications
You must be signed in to change notification settings - Fork 32.2k
gh-123614: Add save function to turtle.py #123617
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
Co-authored-by: Marie Roald <[email protected]>
Most changes to Python require a NEWS entry. Add one using the blurb_it web app or the blurb command-line tool. If this change has little impact on Python users, wait for a maintainer to apply the |
Co-authored-by: Marie Roald <[email protected]>
Could you add documentation? And I would raise |
Co-authored-by: Yngve Mardal Moe <[email protected]>
Co-authored-by: Yngve Mardal Moe <[email protected]>
Co-authored-by: Yngve Mardal Moe <[email protected]>
We have updated the documentation now and changed the code to use the |
Misc/NEWS.d/next/Core_and_Builtins/2024-09-02-20-39-10.gh-issue-123614.26TMHp.rst
Outdated
Show resolved
Hide resolved
Co-authored-by: Hugo van Kemenade <[email protected]>
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.
Thank you!
Adds a
save(filename: str, overwrite: bool = False)
-function toturtle.py
with the following input validation:FileNotFoundError
that explicitly state that the directory is missing if someone tries to save to an non-existing directoryValueError
if the file exists andoverwrite=False
ValueError
if the file does not end withps
oreps
Co-authored-by: Marie Roald [email protected]