Skip to content

bpo-40833: Clarify docstring of Path.rename #20554

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

Merged
merged 1 commit into from
Oct 3, 2020

Conversation

cool-RR
Copy link
Contributor

@cool-RR cool-RR commented May 31, 2020

I made this after I was bitten when assuming Path.rename would take just the new name rather than the full path.

Question: How can I get an automatic backport to 3.8?

https://bugs.python.org/issue40833

@cool-RR cool-RR marked this pull request as ready for review May 31, 2020 14:31
Copy link
Contributor

@remilapeyre remilapeyre left a comment

Choose a reason for hiding this comment

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

Thanks for the PR @cool-RR! Should the documentation at Doc/library/pathlib.rst should be updated too?

@cool-RR
Copy link
Contributor Author

cool-RR commented Jun 6, 2020

Thanks for the feedback. I updated pathlib.rst. I figured I might as well update replace since it's almost the same. In retrospect, it would have be nice if instead of the replace method we just had an exist_ok=False flag on rename, like we do on touch and mkdir.

Copy link
Contributor

@remilapeyre remilapeyre left a comment

Choose a reason for hiding this comment

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

Thanks!

@taleinat taleinat added needs backport to 3.8 needs backport to 3.9 only security fixes skip news docs Documentation in the Doc dir labels Oct 2, 2020
@taleinat
Copy link
Contributor

taleinat commented Oct 2, 2020

Question: How can I get an automatic backport to 3.8?

You ask, and then a triager or committer adds the "needs-backport" tag(s). (We'll usually take care of those anyways, though.)

@cool-RR cool-RR force-pushed the 2020-05-31-pathlib branch from fdaee3d to 5124ca7 Compare October 3, 2020 09:27
Copy link
Contributor

@taleinat taleinat left a comment

Choose a reason for hiding this comment

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

LGTM

@taleinat taleinat merged commit f97e42e into python:master Oct 3, 2020
@miss-islington
Copy link
Contributor

Thanks @cool-RR for the PR, and @taleinat for merging it 🌮🎉.. I'm working now to backport this PR to: 3.8, 3.9.
🐍🍒⛏🤖

miss-islington pushed a commit to miss-islington/cpython that referenced this pull request Oct 3, 2020
…ythonGH-20554)

(cherry picked from commit f97e42e)

Co-authored-by: Ram Rachum <ram@rachum.com>
@bedevere-bot bedevere-bot removed the needs backport to 3.9 only security fixes label Oct 3, 2020
@bedevere-bot
Copy link

GH-22514 is a backport of this pull request to the 3.9 branch.

miss-islington pushed a commit to miss-islington/cpython that referenced this pull request Oct 3, 2020
…ythonGH-20554)

(cherry picked from commit f97e42e)

Co-authored-by: Ram Rachum <ram@rachum.com>
@bedevere-bot
Copy link

GH-22515 is a backport of this pull request to the 3.8 branch.

miss-islington added a commit that referenced this pull request Oct 3, 2020
…H-20554)

(cherry picked from commit f97e42e)

Co-authored-by: Ram Rachum <ram@rachum.com>
@taleinat taleinat added the needs backport to 3.9 only security fixes label Oct 3, 2020
@miss-islington
Copy link
Contributor

Thanks @cool-RR for the PR, and @taleinat for merging it 🌮🎉.. I'm working now to backport this PR to: 3.9.
🐍🍒⛏🤖

miss-islington pushed a commit to miss-islington/cpython that referenced this pull request Oct 3, 2020
…ythonGH-20554)

(cherry picked from commit f97e42e)

Co-authored-by: Ram Rachum <ram@rachum.com>
@bedevere-bot
Copy link

GH-22516 is a backport of this pull request to the 3.9 branch.

@bedevere-bot bedevere-bot removed the needs backport to 3.9 only security fixes label Oct 3, 2020
taleinat pushed a commit that referenced this pull request Oct 3, 2020
…ths (GH-20554)

(cherry picked from commit f97e42e)

Co-authored-by: Ram Rachum <ram@rachum.com>
ambv pushed a commit to ambv/cpython that referenced this pull request Oct 4, 2020
…ths (pythonGH-20554)

(cherry picked from commit f97e42e)

Co-authored-by: Ram Rachum <ram@rachum.com>
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 news
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants