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

stubgen: Fix valid type detection to allow pipe unions#18726

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 1 commit intopython:masterfromchadrik:stubgen/is_valid_fix
Feb 24, 2025

Conversation

@chadrik
Copy link
Contributor

stubgen has a regex which it uses to reject invalid types that are extracted from docstrings. It needed to be updated to support union shorthand:str | int.

@github-actions
Copy link
Contributor

According tomypy_primer, this change doesn't affect type check results on a corpus of open source code. ✅

@chadrik
Copy link
ContributorAuthor

@hamdanal@JelleZijlstra This is ready for review.

@JelleZijlstraJelleZijlstra merged commit66dde14 intopython:masterFeb 24, 2025
19 checks passed
x612skm pushed a commit to x612skm/mypy-dev that referenced this pull requestFeb 24, 2025
<!-- If this pull request fixes an issue, add "Fixes #NNN" with theissue number. -->`stubgen` has a regex which it uses to reject invalid types that areextracted from docstrings. It needed to be updated to support unionshorthand: `str | int`.<!--Checklist:- Read the [ContributingGuidelines](https://github.com/python/mypy/blob/master/CONTRIBUTING.md)- Add tests for all changed behaviour.- If you can't add a test, please explain why and how you verified yourchanges work.- Make sure CI passes.- Please do not force push to the PR once it has been reviewed.-->
@chadrikchadrik deleted the stubgen/is_valid_fix branchNovember 2, 2025 01:43
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.

2 participants

@chadrik@JelleZijlstra

[8]ページ先頭

©2009-2025 Movatter.jp