Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

gh-112139: Addinspect.Signature.format and use it inpydoc#112143

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
JelleZijlstra merged 7 commits intopython:mainfromsobolevn:issue-112139
Dec 2, 2023

Conversation

@sobolevn
Copy link
Member

@sobolevnsobolevn commentedNov 16, 2023
edited by bedevere-appbot
Loading

What do you think about__str__ with a parameter? Or should we add an alias for this, likedef to_string(self, *, pretty)?

Copy link
Member

@JelleZijlstraJelleZijlstra left a comment

Choose a reason for hiding this comment

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

Thanks, it's great this is relatively simple to implement.

Should we make this a public, supported feature ofinspect.signature? It may be useful for users other thanpydoc. For example, we could add a__format__. Then perhaps something likef"{sig:78p}" could be used.

@sobolevn
Copy link
MemberAuthor

Yes, I think we should add a new method calledformat toinspect.Signature and properly document it.

JelleZijlstra reacted with thumbs up emoji

@sobolevnsobolevn changed the titlegh-112139: Addpretty toinspect.Signature and use it inpydocgh-112139: Addinspect.Signature.format and use it inpydocNov 18, 2023
Copy link
Member

@JelleZijlstraJelleZijlstra left a comment

Choose a reason for hiding this comment

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

Thank you! Sorry I forgot about reviewing this PR.

@AlexWaygood
Copy link
Member

Wow, this is going to be a big quality-of-life improvement. Thanks@sobolevn and@JelleZijlstra! :D

aisk pushed a commit to aisk/cpython that referenced this pull requestFeb 11, 2024
…python#112143)Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
Glyphack pushed a commit to Glyphack/cpython that referenced this pull requestSep 2, 2024
…python#112143)Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment

Reviewers

@JelleZijlstraJelleZijlstraJelleZijlstra approved these changes

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

3 participants

@sobolevn@AlexWaygood@JelleZijlstra

[8]ページ先頭

©2009-2025 Movatter.jp