#36903: inspect.signature should use FORWARDREF annotation_format for python
3.14+
------------------------------+--------------------------------------
Reporter: 93578237 | Owner: (none)
Type: Bug | Status: new
Component: Core (Other) | Version: 6.0
Severity: Normal | Resolution:
Keywords: | Triage Stage: Unreviewed
Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
------------------------------+--------------------------------------
Description changed by 93578237:
Old description:
> On python 3.14 it fails at least here:
> https://github.com/django/django/blob/13299a6203f4bc3e5b2552c96a51ff2b15da3c43/django/contrib/auth/__init__.py#L43
>
> Maybe a new function `signature` should be added to utils/inspect.py
New description:
On python 3.14 it fails at least here:
https://github.com/django/django/blob/13299a6203f4bc3e5b2552c96a51ff2b15da3c43/django/contrib/auth/__init__.py#L43
{{{
import typing as t
if t.TYPE_CHECKING:
from django.http import HttpRequest
from testproject.models import User as UserModel
class AuthenticationBackend(ModelBackend):
def authenticate(
self,
request: HttpRequest | None = None,
username: str | None = None,
password: str | None = None,
**kwargs: t.Any,
) -> UserModel | None: ...
}}}
Maybe a new function `signature` should be added to utils/inspect.py
--
--
Ticket URL: <https://code.djangoproject.com/ticket/36903#comment:1>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.
--
You received this message because you are subscribed to the Google Groups
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion visit
https://groups.google.com/d/msgid/django-updates/0107019c2dd44e03-28766119-3b7b-4012-98db-65a2d0c9f3cc-000000%40eu-central-1.amazonses.com.