gh-62734: Document that open()'s file param becomes name attribute#144455
gh-62734: Document that open()'s file param becomes name attribute#144455kovan wants to merge 2 commits intopython:mainfrom
Conversation
Clarify that the value passed as the *file* parameter to open() is stored in the name attribute of the returned file object. Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
The name attribute is documented under io.FileIO, not io.IOBase. Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
ZeroIntensity
left a comment
There was a problem hiding this comment.
Please take the history of the issue into account before opening a PR. It's not clear that this is the immediate change that we want to make.
More generally, please do not spam us with AI-generated pull requests. Despite what you might think, these are often not helpful contributions and waste maintainer time.
If you're interested in contributing to CPython, I really suggest finding an area that you're interested in, spending the time to thoroughly investigate and triage an issue, and then finally submitting a PR. Otherwise, if you continue to do this, we have no choice but to block you.
|
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 |
|
Block me? haha that's funny. I can just open another GitHub account, eliminate any trace of AI intervention in the commits and PRs and you will have to use your brain to know if the commit is appropiate or not, instead of just preaching. |
If you can do that, then please do! We only care about AI-generated PRs and issues when they're incorrect, and thus waste maintainer time. CPython is almost entirely maintained by volunteers, so we don't have the time to review and fix AI code in addition to the thousands of PRs that are already on our backlog. If you can put enough effort into fixing AI-generated code that we don't notice, then we'll treat it the same as we do any other contribution. I think you got the impression that we have some vendetta against AI. Our policy allows AI, as long as it's used correctly. All that said, I'm going to close this. Your comment is in violation of our Code of Conduct, and by the sounds of it, you're also in violation of GitHub's Code of Conduct. |
Summary
open()is stored in thenameattribute of the returned file objectTest plan
make checkpassed🤖 Generated with Claude Code
📚 Documentation preview 📚: https://cpython-previews--144455.org.readthedocs.build/