[issue45684] `functools.singledispatchmethod` does not define `__class_getitem__`

2021-12-12 Thread Alex Waygood
Alex Waygood added the comment: Closing this, as I don't think the use case I presented is strong enough, and there are ultimately more important things to worry about. -- resolution: -> not a bug stage: patch review -> resolved status: open -> closed

[issue45684] `functools.singledispatchmethod` does not define `__class_getitem__`

2021-11-06 Thread Alex Waygood
Alex Waygood added the comment: ^ I posted the wrong link for the example; it should have been: https://mypy-play.net/?mypy=latest=3.10=show-error-codes%2Cstrict=6a26d31899f9803a823662261eae21df -- ___ Python tracker

[issue45684] `functools.singledispatchmethod` does not define `__class_getitem__`

2021-11-05 Thread Alex Waygood
Alex Waygood added the comment: To clarify why this is an issue: It's probably quite improbable that anybody would ever need to use `singledispatchmethod` in a type annotation. But, if they do, they'll find themselves in an impossible situation if they're using mypy with the `--strict`

[issue45684] `functools.singledispatchmethod` does not define `__class_getitem__`

2021-11-01 Thread Alex Waygood
Change by Alex Waygood : -- keywords: +patch pull_requests: +27615 stage: -> patch review pull_request: https://github.com/python/cpython/pull/29355 ___ Python tracker ___

[issue45684] `functools.singledispatchmethod` does not define `__class_getitem__`

2021-11-01 Thread Alex Waygood
New submission from Alex Waygood : `functools.singledispatchmethod` is marked as being a generic class in `typeshed`, but does not define `__class_getitem__`, so cannot be parameterized at runtime. cpython source code: