Skip to content

add ParamSpec to asyncio.to_thread #6668

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 4 commits into from
Dec 23, 2021
Merged

add ParamSpec to asyncio.to_thread #6668

merged 4 commits into from
Dec 23, 2021

Conversation

graingert
Copy link
Contributor

No description provided.

@graingert
Copy link
Contributor Author

hmm stubtest doesn't like the ParamSpec _P here:


C:\hostedtoolcache\windows\Python\3.9.9\x64\python.exe -m mypy.stubtest --check-typeshed --custom-typeshed-dir . --allowlist tests\stubtest_allowlists\py3_common.txt --allowlist tests\stubtest_allowlists\py39.txt --allowlist tests\stubtest_allowlists\win32.txt --allowlist tests\stubtest_allowlists\win32-py39.txt --ignore-positional-only
error: not checking stubs due to mypy build errors:
stdlib\asyncio\threads.pyi:9: error: Name "_P.args" is not defined
stdlib\asyncio\threads.pyi:9: error: Name "_P.kwargs" is not defined

@github-actions

This comment has been minimized.

1 similar comment
@github-actions

This comment has been minimized.

@JelleZijlstra
Copy link
Member

I just merged a PR upgrading stubtest to 0.930, let's see if that helps.

@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@github-actions
Copy link
Contributor

According to mypy_primer, this change has no effect on the checked open source code. 🤖🎉

Copy link
Collaborator

@Akuli Akuli left a comment

Choose a reason for hiding this comment

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

It might be good to remove # type: ignore comments from other uses of ParamSpec, as they no longer seem to be necessary. CONTRIBUTING.md should be updated too.

@Akuli Akuli merged commit eced701 into python:master Dec 23, 2021
@graingert graingert deleted the patch-2 branch December 23, 2021 11:50
@graingert
Copy link
Contributor Author

It might be good to remove # type: ignore comments from other uses of ParamSpec, as they no longer seem to be necessary. CONTRIBUTING.md should be updated too.

Can CI check for unused ignores?

@srittau
Copy link
Collaborator

srittau commented Dec 23, 2021

Can CI check for unused ignores?

Unfortunately not, because different type checkers might have different opinions about that.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants