mirror of
https://github.com/davidhalter/django-stubs.git
synced 2025-12-08 21:14:49 +08:00
black reformat, some fixes
This commit is contained in:
@@ -21,7 +21,12 @@ def url(
|
||||
]
|
||||
],
|
||||
kwargs: Optional[
|
||||
Union[Dict[str, Dict[str, Type[FlatPageSitemap]]], Dict[str, Dict[str, Sitemap]], Dict[str, OrderedDict], Dict[str, str]]
|
||||
Union[
|
||||
Dict[str, Dict[str, Type[FlatPageSitemap]]],
|
||||
Dict[str, Dict[str, Sitemap]],
|
||||
Dict[str, OrderedDict],
|
||||
Dict[str, str],
|
||||
]
|
||||
] = ...,
|
||||
name: Optional[str] = ...,
|
||||
) -> Union[URLPattern, URLResolver]: ...
|
||||
|
||||
@@ -13,7 +13,9 @@ class ListFilter:
|
||||
title: Any = ...
|
||||
template: str = ...
|
||||
used_parameters: Any = ...
|
||||
def __init__(self, request: WSGIRequest, params: Dict[str, str], model: Type[Model], model_admin: ModelAdmin) -> None: ...
|
||||
def __init__(
|
||||
self, request: WSGIRequest, params: Dict[str, str], model: Type[Model], model_admin: ModelAdmin
|
||||
) -> None: ...
|
||||
def has_output(self) -> None: ...
|
||||
def choices(self, changelist: Any) -> None: ...
|
||||
def queryset(self, request: Any, queryset: Any) -> None: ...
|
||||
@@ -22,7 +24,9 @@ class ListFilter:
|
||||
class SimpleListFilter(ListFilter):
|
||||
parameter_name: Any = ...
|
||||
lookup_choices: Any = ...
|
||||
def __init__(self, request: WSGIRequest, params: Dict[str, str], model: Type[Model], model_admin: ModelAdmin) -> None: ...
|
||||
def __init__(
|
||||
self, request: WSGIRequest, params: Dict[str, str], model: Type[Model], model_admin: ModelAdmin
|
||||
) -> None: ...
|
||||
def has_output(self) -> bool: ...
|
||||
def value(self) -> Optional[str]: ...
|
||||
def lookups(self, request: Any, model_admin: Any) -> None: ...
|
||||
|
||||
@@ -70,7 +70,9 @@ class Fieldline:
|
||||
has_visible_field: Any = ...
|
||||
model_admin: Any = ...
|
||||
readonly_fields: Any = ...
|
||||
def __init__(self, form: Any, field: Any, readonly_fields: Optional[Any] = ..., model_admin: Optional[Any] = ...) -> None: ...
|
||||
def __init__(
|
||||
self, form: Any, field: Any, readonly_fields: Optional[Any] = ..., model_admin: Optional[Any] = ...
|
||||
) -> None: ...
|
||||
def __iter__(self) -> Iterator[Union[AdminField, AdminReadonlyField]]: ...
|
||||
def errors(self) -> SafeText: ...
|
||||
|
||||
|
||||
@@ -21,7 +21,9 @@ class LogEntryManager(models.Manager):
|
||||
object_id: Union[int, str, UUID],
|
||||
object_repr: str,
|
||||
action_flag: int,
|
||||
change_message: Union[Dict[str, Dict[str, List[str]]], List[Dict[str, Dict[str, Union[List[str], str]]]], str] = ...,
|
||||
change_message: Union[
|
||||
Dict[str, Dict[str, List[str]]], List[Dict[str, Dict[str, Union[List[str], str]]]], str
|
||||
] = ...,
|
||||
) -> LogEntry: ...
|
||||
|
||||
class LogEntry(models.Model):
|
||||
|
||||
@@ -141,10 +141,18 @@ class ModelAdmin(BaseModelAdmin):
|
||||
def get_changelist_formset(self, request: Any, **kwargs: Any): ...
|
||||
def get_formsets_with_inlines(self, request: WSGIRequest, obj: Optional[Model] = ...) -> None: ...
|
||||
def get_paginator(
|
||||
self, request: WSGIRequest, queryset: QuerySet, per_page: int, orphans: int = ..., allow_empty_first_page: bool = ...
|
||||
self,
|
||||
request: WSGIRequest,
|
||||
queryset: QuerySet,
|
||||
per_page: int,
|
||||
orphans: int = ...,
|
||||
allow_empty_first_page: bool = ...,
|
||||
) -> Paginator: ...
|
||||
def log_addition(
|
||||
self, request: WSGIRequest, object: Model, message: Union[Dict[str, Dict[Any, Any]], List[Dict[str, Dict[str, str]]]]
|
||||
self,
|
||||
request: WSGIRequest,
|
||||
object: Model,
|
||||
message: Union[Dict[str, Dict[Any, Any]], List[Dict[str, Dict[str, str]]]],
|
||||
) -> LogEntry: ...
|
||||
def log_change(
|
||||
self,
|
||||
@@ -155,7 +163,9 @@ class ModelAdmin(BaseModelAdmin):
|
||||
def log_deletion(self, request: WSGIRequest, object: Model, object_repr: str) -> LogEntry: ...
|
||||
def action_checkbox(self, obj: Model) -> SafeText: ...
|
||||
def get_actions(self, request: WSGIRequest) -> OrderedDict: ...
|
||||
def get_action_choices(self, request: WSGIRequest, default_choices: List[Tuple[str, str]] = ...) -> List[Tuple[str, str]]: ...
|
||||
def get_action_choices(
|
||||
self, request: WSGIRequest, default_choices: List[Tuple[str, str]] = ...
|
||||
) -> List[Tuple[str, str]]: ...
|
||||
def get_action(self, action: Union[Callable, str]) -> Tuple[Callable, str, str]: ...
|
||||
def get_list_display(self, request: WSGIRequest) -> Union[List[Callable], List[str], Tuple[str]]: ...
|
||||
def get_list_display_links(
|
||||
@@ -164,13 +174,20 @@ class ModelAdmin(BaseModelAdmin):
|
||||
def get_list_filter(self, request: WSGIRequest) -> Union[List[Type[SimpleListFilter]], List[str], Tuple]: ...
|
||||
def get_list_select_related(self, request: WSGIRequest) -> Union[Tuple, bool]: ...
|
||||
def get_search_fields(self, request: WSGIRequest) -> Union[List[str], Tuple]: ...
|
||||
def get_search_results(self, request: WSGIRequest, queryset: QuerySet, search_term: str) -> Tuple[QuerySet, bool]: ...
|
||||
def get_search_results(
|
||||
self, request: WSGIRequest, queryset: QuerySet, search_term: str
|
||||
) -> Tuple[QuerySet, bool]: ...
|
||||
def get_preserved_filters(self, request: WSGIRequest) -> str: ...
|
||||
def construct_change_message(
|
||||
self, request: WSGIRequest, form: AdminPasswordChangeForm, formsets: None, add: bool = ...
|
||||
) -> List[Dict[str, Dict[str, List[str]]]]: ...
|
||||
def message_user(
|
||||
self, request: WSGIRequest, message: str, level: Union[int, str] = ..., extra_tags: str = ..., fail_silently: bool = ...
|
||||
self,
|
||||
request: WSGIRequest,
|
||||
message: str,
|
||||
level: Union[int, str] = ...,
|
||||
extra_tags: str = ...,
|
||||
fail_silently: bool = ...,
|
||||
) -> None: ...
|
||||
def save_form(self, request: Any, form: Any, change: Any): ...
|
||||
def save_model(self, request: Any, obj: Any, form: Any, change: Any) -> None: ...
|
||||
@@ -179,7 +196,13 @@ class ModelAdmin(BaseModelAdmin):
|
||||
def save_formset(self, request: Any, form: Any, formset: Any, change: Any) -> None: ...
|
||||
def save_related(self, request: Any, form: Any, formsets: Any, change: Any) -> None: ...
|
||||
def render_change_form(
|
||||
self, request: Any, context: Any, add: bool = ..., change: bool = ..., form_url: str = ..., obj: Optional[Any] = ...
|
||||
self,
|
||||
request: Any,
|
||||
context: Any,
|
||||
add: bool = ...,
|
||||
change: bool = ...,
|
||||
form_url: str = ...,
|
||||
obj: Optional[Any] = ...,
|
||||
): ...
|
||||
def response_add(self, request: WSGIRequest, obj: Model, post_url_continue: None = ...) -> HttpResponse: ...
|
||||
def response_change(self, request: WSGIRequest, obj: Model) -> HttpResponse: ...
|
||||
@@ -204,7 +227,9 @@ class ModelAdmin(BaseModelAdmin):
|
||||
def change_view(
|
||||
self, request: WSGIRequest, object_id: str, form_url: str = ..., extra_context: Optional[Dict[str, bool]] = ...
|
||||
) -> HttpResponse: ...
|
||||
def changelist_view(self, request: WSGIRequest, extra_context: Optional[Dict[str, str]] = ...) -> HttpResponseBase: ...
|
||||
def changelist_view(
|
||||
self, request: WSGIRequest, extra_context: Optional[Dict[str, str]] = ...
|
||||
) -> HttpResponseBase: ...
|
||||
def get_deleted_objects(
|
||||
self, objs: QuerySet, request: WSGIRequest
|
||||
) -> Tuple[List[Any], Dict[Any, Any], Set[Any], List[Any]]: ...
|
||||
|
||||
@@ -28,7 +28,9 @@ def results(cl: ChangeList) -> Iterator[ResultList]: ...
|
||||
def result_hidden_fields(cl: ChangeList) -> Iterator[BoundField]: ...
|
||||
def result_list(
|
||||
cl: ChangeList
|
||||
) -> Dict[str, Union[List[Dict[str, Optional[Union[int, str]]]], List[ResultList], List[BoundField], ChangeList, int]]: ...
|
||||
) -> Dict[
|
||||
str, Union[List[Dict[str, Optional[Union[int, str]]]], List[ResultList], List[BoundField], ChangeList, int]
|
||||
]: ...
|
||||
def result_list_tag(parser: Parser, token: Token) -> InclusionAdminNode: ...
|
||||
def date_hierarchy(cl: ChangeList) -> Optional[Dict[str, Union[Dict[str, str], List[Dict[str, str]], bool]]]: ...
|
||||
def date_hierarchy_tag(parser: Parser, token: Token) -> InclusionAdminNode: ...
|
||||
|
||||
@@ -10,5 +10,8 @@ register: Any
|
||||
def admin_urlname(value: Options, arg: SafeText) -> str: ...
|
||||
def admin_urlquote(value: Union[int, str, UUID]) -> Union[int, str, UUID]: ...
|
||||
def add_preserved_filters(
|
||||
context: Union[Dict[str, Union[Options, str]], RequestContext], url: str, popup: bool = ..., to_field: Optional[str] = ...
|
||||
context: Union[Dict[str, Union[Options, str]], RequestContext],
|
||||
url: str,
|
||||
popup: bool = ...,
|
||||
to_field: Optional[str] = ...,
|
||||
) -> str: ...
|
||||
|
||||
@@ -11,5 +11,7 @@ class InclusionAdminNode(InclusionNode):
|
||||
kwargs: Dict[Any, Any]
|
||||
takes_context: bool
|
||||
template_name: str = ...
|
||||
def __init__(self, parser: Parser, token: Token, func: Callable, template_name: str, takes_context: bool = ...) -> None: ...
|
||||
def __init__(
|
||||
self, parser: Parser, token: Token, func: Callable, template_name: str, takes_context: bool = ...
|
||||
) -> None: ...
|
||||
def render(self, context: Context) -> SafeText: ...
|
||||
|
||||
@@ -65,7 +65,9 @@ def label_for_field(
|
||||
name: Union[Callable, str], model: Type[Model], model_admin: Optional[BaseModelAdmin] = ..., return_attr: bool = ...
|
||||
) -> Union[Tuple[Optional[str], Union[Callable, Type[str]]], str]: ...
|
||||
def help_text_for_field(name: str, model: Type[Model]) -> str: ...
|
||||
def display_for_field(value: Any, field: Union[Field, reverse_related.OneToOneRel], empty_value_display: str) -> str: ...
|
||||
def display_for_field(
|
||||
value: Any, field: Union[Field, reverse_related.OneToOneRel], empty_value_display: str
|
||||
) -> str: ...
|
||||
def display_for_value(value: Any, empty_value_display: str, boolean: bool = ...) -> str: ...
|
||||
|
||||
class NotRelationField(Exception): ...
|
||||
|
||||
@@ -60,7 +60,9 @@ class ChangeList:
|
||||
) -> None: ...
|
||||
def get_filters_params(self, params: None = ...) -> Dict[str, str]: ...
|
||||
def get_filters(self, request: WSGIRequest) -> Tuple[List[ListFilter], bool, Dict[str, Union[bool, str]], bool]: ...
|
||||
def get_query_string(self, new_params: Optional[Dict[str, None]] = ..., remove: Optional[List[str]] = ...) -> str: ...
|
||||
def get_query_string(
|
||||
self, new_params: Optional[Dict[str, None]] = ..., remove: Optional[List[str]] = ...
|
||||
) -> str: ...
|
||||
result_count: Any = ...
|
||||
show_full_result_count: Any = ...
|
||||
show_admin_actions: Any = ...
|
||||
|
||||
@@ -84,7 +84,9 @@ class AdminFileWidget(forms.ClearableFileInput):
|
||||
template_name: str = ...
|
||||
|
||||
def url_params_from_lookup_dict(
|
||||
lookups: Union[Dict[str, Callable], Dict[str, List[str]], Dict[str, Tuple[str, str]], Dict[str, bool], Dict[str, str], Q]
|
||||
lookups: Union[
|
||||
Dict[str, Callable], Dict[str, List[str]], Dict[str, Tuple[str, str]], Dict[str, bool], Dict[str, str], Q
|
||||
]
|
||||
) -> Dict[str, str]: ...
|
||||
|
||||
class ForeignKeyRawIdWidget(forms.TextInput):
|
||||
@@ -148,7 +150,9 @@ class RelatedFieldWidgetWrapper(forms.Widget):
|
||||
def get_context(
|
||||
self, name: str, value: Optional[Union[int, str]], attrs: Optional[Dict[str, Union[bool, str]]]
|
||||
) -> Dict[str, Union[bool, str]]: ...
|
||||
def value_from_datadict(self, data: QueryDict, files: MultiValueDict, name: str) -> Optional[Union[List[str], str]]: ...
|
||||
def value_from_datadict(
|
||||
self, data: QueryDict, files: MultiValueDict, name: str
|
||||
) -> Optional[Union[List[str], str]]: ...
|
||||
def value_omitted_from_data(self, data: Dict[Any, Any], files: Dict[Any, Any], name: str) -> bool: ...
|
||||
def id_for_label(self, id_: str) -> str: ...
|
||||
|
||||
|
||||
@@ -11,7 +11,13 @@ ROLES: Any
|
||||
|
||||
def create_reference_role(rolename: Any, urlbase: Any): ...
|
||||
def default_reference_role(
|
||||
name: Any, rawtext: Any, text: Any, lineno: Any, inliner: Any, options: Optional[Any] = ..., content: Optional[Any] = ...
|
||||
name: Any,
|
||||
rawtext: Any,
|
||||
text: Any,
|
||||
lineno: Any,
|
||||
inliner: Any,
|
||||
options: Optional[Any] = ...,
|
||||
content: Optional[Any] = ...,
|
||||
): ...
|
||||
|
||||
named_group_matcher: Any
|
||||
|
||||
@@ -18,7 +18,9 @@ REDIRECT_FIELD_NAME: str
|
||||
def load_backend(path: str) -> ModelBackend: ...
|
||||
def get_backends() -> List[ModelBackend]: ...
|
||||
def authenticate(request: Any = ..., **credentials: Any) -> Optional[AbstractBaseUser]: ...
|
||||
def login(request: HttpRequest, user: AbstractBaseUser, backend: Optional[Union[Type[ModelBackend], str]] = ...) -> None: ...
|
||||
def login(
|
||||
request: HttpRequest, user: AbstractBaseUser, backend: Optional[Union[Type[ModelBackend], str]] = ...
|
||||
) -> None: ...
|
||||
def logout(request: HttpRequest) -> None: ...
|
||||
def get_user_model() -> Type[Model]: ...
|
||||
def get_user(request: HttpRequest) -> Union[AbstractBaseUser, AnonymousUser]: ...
|
||||
|
||||
@@ -14,7 +14,9 @@ class ModelBackend:
|
||||
def get_user_permissions(self, user_obj: AbstractBaseUser, obj: None = ...) -> Set[str]: ...
|
||||
def get_group_permissions(self, user_obj: AbstractBaseUser, obj: None = ...) -> Set[str]: ...
|
||||
def get_all_permissions(self, user_obj: AbstractBaseUser, obj: Optional[str] = ...) -> Set[str]: ...
|
||||
def has_perm(self, user_obj: Union[AbstractBaseUser, AnonymousUser], perm: str, obj: Optional[str] = ...) -> bool: ...
|
||||
def has_perm(
|
||||
self, user_obj: Union[AbstractBaseUser, AnonymousUser], perm: str, obj: Optional[str] = ...
|
||||
) -> bool: ...
|
||||
def has_module_perms(self, user_obj: Union[AbstractBaseUser, AnonymousUser], app_label: str) -> bool: ...
|
||||
def get_user(self, user_id: int) -> AbstractBaseUser: ...
|
||||
|
||||
|
||||
@@ -1,6 +1,8 @@
|
||||
from typing import Any, Callable, List, Optional, Set, Union
|
||||
|
||||
def user_passes_test(test_func: Callable, login_url: Optional[str] = ..., redirect_field_name: str = ...) -> Callable: ...
|
||||
def user_passes_test(
|
||||
test_func: Callable, login_url: Optional[str] = ..., redirect_field_name: str = ...
|
||||
) -> Callable: ...
|
||||
def login_required(
|
||||
function: Optional[Callable] = ..., redirect_field_name: str = ..., login_url: Optional[str] = ...
|
||||
) -> Callable: ...
|
||||
|
||||
@@ -5,7 +5,9 @@ UNUSABLE_PASSWORD_PREFIX: str
|
||||
UNUSABLE_PASSWORD_SUFFIX_LENGTH: int
|
||||
|
||||
def is_password_usable(encoded: Optional[str]) -> bool: ...
|
||||
def check_password(password: Optional[str], encoded: str, setter: Optional[Callable] = ..., preferred: str = ...) -> bool: ...
|
||||
def check_password(
|
||||
password: Optional[str], encoded: str, setter: Optional[Callable] = ..., preferred: str = ...
|
||||
) -> bool: ...
|
||||
def make_password(password: Optional[str], salt: Optional[str] = ..., hasher: str = ...) -> str: ...
|
||||
def get_hashers() -> List[BasePasswordHasher]: ...
|
||||
def get_hashers_by_algorithm() -> Dict[str, BasePasswordHasher]: ...
|
||||
|
||||
@@ -4,7 +4,12 @@ from django.apps.config import AppConfig
|
||||
from django.apps.registry import Apps
|
||||
|
||||
def create_permissions(
|
||||
app_config: AppConfig, verbosity: int = ..., interactive: bool = ..., using: str = ..., apps: Apps = ..., **kwargs: Any
|
||||
app_config: AppConfig,
|
||||
verbosity: int = ...,
|
||||
interactive: bool = ...,
|
||||
using: str = ...,
|
||||
apps: Apps = ...,
|
||||
**kwargs: Any
|
||||
) -> None: ...
|
||||
def get_system_username() -> str: ...
|
||||
def get_default_username(check_db: bool = ...) -> str: ...
|
||||
|
||||
@@ -4,14 +4,18 @@ from typing import Any, Dict, List, Optional, Tuple, Union
|
||||
from django.contrib.auth.base_user import AbstractBaseUser
|
||||
from django.contrib.auth.models import User
|
||||
|
||||
def get_default_password_validators() -> Union[List[NumericPasswordValidator], List[UserAttributeSimilarityValidator]]: ...
|
||||
def get_default_password_validators() -> Union[
|
||||
List[NumericPasswordValidator], List[UserAttributeSimilarityValidator]
|
||||
]: ...
|
||||
def get_password_validators(
|
||||
validator_config: List[Dict[str, Union[Dict[str, int], str]]]
|
||||
) -> Union[List[NumericPasswordValidator], List[UserAttributeSimilarityValidator]]: ...
|
||||
def validate_password(
|
||||
password: str, user: Optional[AbstractBaseUser] = ..., password_validators: Optional[List[Any]] = ...
|
||||
) -> None: ...
|
||||
def password_changed(password: str, user: Optional[AbstractBaseUser] = ..., password_validators: None = ...) -> None: ...
|
||||
def password_changed(
|
||||
password: str, user: Optional[AbstractBaseUser] = ..., password_validators: None = ...
|
||||
) -> None: ...
|
||||
def password_validators_help_texts(password_validators: Optional[List[Any]] = ...) -> List[str]: ...
|
||||
|
||||
password_validators_help_text_html: Any
|
||||
|
||||
@@ -32,7 +32,9 @@ class LoginView(SuccessURLAllowedHostsMixin, FormView):
|
||||
def get_form_class(self) -> Type[AuthenticationForm]: ...
|
||||
def get_form_kwargs(self) -> Dict[str, Optional[Union[Dict[str, str], HttpRequest, MultiValueDict]]]: ...
|
||||
def form_valid(self, form: AuthenticationForm) -> HttpResponseRedirect: ...
|
||||
def get_context_data(self, **kwargs: Any) -> Dict[str, Union[AuthenticationForm, LoginView, Site, RequestSite, str]]: ...
|
||||
def get_context_data(
|
||||
self, **kwargs: Any
|
||||
) -> Dict[str, Union[AuthenticationForm, LoginView, Site, RequestSite, str]]: ...
|
||||
|
||||
class LogoutView(SuccessURLAllowedHostsMixin, TemplateView):
|
||||
next_page: Any = ...
|
||||
|
||||
@@ -41,7 +41,9 @@ class GenericForeignKey(FieldCacheMixin):
|
||||
def get_prefetch_queryset(
|
||||
self, instances: Union[List[Model], QuerySet], queryset: Optional[QuerySet] = ...
|
||||
) -> Tuple[List[Model], Callable, Callable, bool, str, bool]: ...
|
||||
def __get__(self, instance: Optional[Model], cls: Type[Model] = ...) -> Optional[Union[GenericForeignKey, Model]]: ...
|
||||
def __get__(
|
||||
self, instance: Optional[Model], cls: Type[Model] = ...
|
||||
) -> Optional[Union[GenericForeignKey, Model]]: ...
|
||||
def __set__(self, instance: Model, value: Optional[Model]) -> None: ...
|
||||
|
||||
class GenericRel(ForeignObjectRel):
|
||||
@@ -95,7 +97,9 @@ class GenericRelation(ForeignObject):
|
||||
def set_attributes_from_rel(self) -> None: ...
|
||||
def get_internal_type(self) -> str: ...
|
||||
def get_content_type(self) -> ContentType: ...
|
||||
def get_extra_restriction(self, where_class: Type[WhereNode], alias: Optional[str], remote_alias: str) -> WhereNode: ...
|
||||
def get_extra_restriction(
|
||||
self, where_class: Type[WhereNode], alias: Optional[str], remote_alias: str
|
||||
) -> WhereNode: ...
|
||||
def bulk_related_objects(self, objs: List[Model], using: str = ...) -> QuerySet: ...
|
||||
|
||||
class ReverseGenericManyToOneDescriptor(ReverseManyToOneDescriptor):
|
||||
|
||||
@@ -24,5 +24,10 @@ def get_contenttypes_and_models(
|
||||
app_config: AppConfig, using: str, ContentType: Type[ContentType]
|
||||
) -> Tuple[Dict[str, ContentType], Dict[str, Type[Model]]]: ...
|
||||
def create_contenttypes(
|
||||
app_config: AppConfig, verbosity: int = ..., interactive: bool = ..., using: str = ..., apps: Apps = ..., **kwargs: Any
|
||||
app_config: AppConfig,
|
||||
verbosity: int = ...,
|
||||
interactive: bool = ...,
|
||||
using: str = ...,
|
||||
apps: Apps = ...,
|
||||
**kwargs: Any
|
||||
) -> None: ...
|
||||
|
||||
@@ -3,4 +3,6 @@ from typing import Any, Optional, Union
|
||||
from django.http.request import HttpRequest
|
||||
from django.http.response import HttpResponseRedirect
|
||||
|
||||
def shortcut(request: HttpRequest, content_type_id: Union[int, str], object_id: Union[int, str]) -> HttpResponseRedirect: ...
|
||||
def shortcut(
|
||||
request: HttpRequest, content_type_id: Union[int, str], object_id: Union[int, str]
|
||||
) -> HttpResponseRedirect: ...
|
||||
|
||||
@@ -7,13 +7,21 @@ from django.http.request import HttpRequest
|
||||
class MessageFailure(Exception): ...
|
||||
|
||||
def add_message(
|
||||
request: Optional[WSGIRequest], level: int, message: str, extra_tags: str = ..., fail_silently: Union[bool, str] = ...
|
||||
request: Optional[WSGIRequest],
|
||||
level: int,
|
||||
message: str,
|
||||
extra_tags: str = ...,
|
||||
fail_silently: Union[bool, str] = ...,
|
||||
) -> None: ...
|
||||
def get_messages(request: HttpRequest) -> Union[List[Any], BaseStorage]: ...
|
||||
def get_level(request: HttpRequest) -> int: ...
|
||||
def set_level(request: HttpRequest, level: int) -> bool: ...
|
||||
def debug(request: WSGIRequest, message: str, extra_tags: str = ..., fail_silently: Union[bool, str] = ...) -> None: ...
|
||||
def info(request: WSGIRequest, message: str, extra_tags: str = ..., fail_silently: Union[bool, str] = ...) -> None: ...
|
||||
def success(request: WSGIRequest, message: str, extra_tags: str = ..., fail_silently: Union[bool, str] = ...) -> None: ...
|
||||
def warning(request: WSGIRequest, message: str, extra_tags: str = ..., fail_silently: Union[bool, str] = ...) -> None: ...
|
||||
def success(
|
||||
request: WSGIRequest, message: str, extra_tags: str = ..., fail_silently: Union[bool, str] = ...
|
||||
) -> None: ...
|
||||
def warning(
|
||||
request: WSGIRequest, message: str, extra_tags: str = ..., fail_silently: Union[bool, str] = ...
|
||||
) -> None: ...
|
||||
def error(request: WSGIRequest, message: str, extra_tags: str = ..., fail_silently: Union[bool, str] = ...) -> None: ...
|
||||
|
||||
@@ -19,7 +19,9 @@ class MessageDecoder(json.JSONDecoder):
|
||||
def process_messages(
|
||||
self,
|
||||
obj: Union[
|
||||
Dict[str, Union[List[Union[Dict[str, List[Union[int, str]]], List[Union[int, str]]]], List[Union[int, str]]]],
|
||||
Dict[
|
||||
str, Union[List[Union[Dict[str, List[Union[int, str]]], List[Union[int, str]]]], List[Union[int, str]]]
|
||||
],
|
||||
List[Union[List[Union[int, str]], str]],
|
||||
str,
|
||||
],
|
||||
|
||||
@@ -10,4 +10,6 @@ class SessionStorage(BaseStorage):
|
||||
session_key: str = ...
|
||||
def __init__(self, request: HttpRequest, *args: Any, **kwargs: Any) -> None: ...
|
||||
def serialize_messages(self, messages: Union[List[Message], List[str]]) -> str: ...
|
||||
def deserialize_messages(self, data: Optional[Union[List[Any], str]]) -> Optional[Union[List[Message], List[str]]]: ...
|
||||
def deserialize_messages(
|
||||
self, data: Optional[Union[List[Any], str]]
|
||||
) -> Optional[Union[List[Message], List[str]]]: ...
|
||||
|
||||
@@ -19,7 +19,11 @@ class JSONField(CheckFieldDefaultMixin, Field):
|
||||
default_error_messages: Any = ...
|
||||
encoder: Any = ...
|
||||
def __init__(
|
||||
self, verbose_name: None = ..., name: None = ..., encoder: Optional[Type[DjangoJSONEncoder]] = ..., **kwargs: Any
|
||||
self,
|
||||
verbose_name: None = ...,
|
||||
name: None = ...,
|
||||
encoder: Optional[Type[DjangoJSONEncoder]] = ...,
|
||||
**kwargs: Any
|
||||
) -> None: ...
|
||||
def db_type(self, connection: Any): ...
|
||||
def deconstruct(self) -> Tuple[None, str, List[Any], Dict[str, Union[Type[DjangoJSONEncoder], bool]]]: ...
|
||||
|
||||
@@ -4,5 +4,10 @@ from django.apps.registry import Apps
|
||||
from django.contrib.sites.apps import SitesConfig
|
||||
|
||||
def create_default_site(
|
||||
app_config: SitesConfig, verbosity: int = ..., interactive: bool = ..., using: str = ..., apps: Apps = ..., **kwargs: Any
|
||||
app_config: SitesConfig,
|
||||
verbosity: int = ...,
|
||||
interactive: bool = ...,
|
||||
using: str = ...,
|
||||
apps: Apps = ...,
|
||||
**kwargs: Any
|
||||
) -> None: ...
|
||||
|
||||
@@ -22,7 +22,9 @@ class HashedFilesMixin:
|
||||
def hashed_name(self, name: str, content: Optional[File] = ..., filename: Optional[str] = ...) -> str: ...
|
||||
def url(self, name: SafeText, force: bool = ...) -> str: ...
|
||||
def url_converter(self, name: str, hashed_files: OrderedDict, template: str = ...) -> Callable: ...
|
||||
def post_process(self, paths: OrderedDict, dry_run: bool = ..., **options: Any) -> Iterator[Tuple[str, str, bool]]: ...
|
||||
def post_process(
|
||||
self, paths: OrderedDict, dry_run: bool = ..., **options: Any
|
||||
) -> Iterator[Tuple[str, str, bool]]: ...
|
||||
def clean_name(self, name: str) -> str: ...
|
||||
def hash_key(self, name: str) -> str: ...
|
||||
def stored_name(self, name: str) -> str: ...
|
||||
|
||||
@@ -10,7 +10,9 @@ class DummyCache(BaseCache):
|
||||
def __init__(self, host: str, *args: Any, **kwargs: Any) -> None: ...
|
||||
def add(self, key: str, value: str, timeout: Any = ..., version: None = ...) -> bool: ...
|
||||
def get(self, key: str, default: Optional[str] = ..., version: Optional[int] = ...) -> Optional[str]: ...
|
||||
def set(self, key: str, value: Union[Dict[str, Any], int, str], timeout: Any = ..., version: Optional[str] = ...) -> None: ...
|
||||
def set(
|
||||
self, key: str, value: Union[Dict[str, Any], int, str], timeout: Any = ..., version: Optional[str] = ...
|
||||
) -> None: ...
|
||||
def touch(self, key: str, timeout: Any = ..., version: None = ...) -> bool: ...
|
||||
def delete(self, key: str, version: None = ...) -> None: ...
|
||||
def has_key(self, key: str, version: None = ...) -> bool: ...
|
||||
|
||||
@@ -12,7 +12,9 @@ class FileBasedCache(BaseCache):
|
||||
def add(
|
||||
self, key: str, value: Union[Dict[str, int], bytes, int, str], timeout: Any = ..., version: Optional[int] = ...
|
||||
) -> bool: ...
|
||||
def get(self, key: str, default: Optional[Union[int, str]] = ..., version: Optional[int] = ...) -> Optional[str]: ...
|
||||
def get(
|
||||
self, key: str, default: Optional[Union[int, str]] = ..., version: Optional[int] = ...
|
||||
) -> Optional[str]: ...
|
||||
def set(self, key: str, value: Any, timeout: Any = ..., version: Optional[int] = ...) -> None: ...
|
||||
def touch(self, key: str, timeout: Any = ..., version: None = ...) -> bool: ...
|
||||
def delete(self, key: str, version: Optional[int] = ...) -> None: ...
|
||||
|
||||
@@ -15,7 +15,9 @@ class LocMemCache(BaseCache):
|
||||
timeout: Any = ...,
|
||||
version: Optional[int] = ...,
|
||||
) -> Any: ...
|
||||
def get(self, key: Union[int, str], default: Optional[Union[int, str]] = ..., version: Optional[int] = ...) -> Any: ...
|
||||
def get(
|
||||
self, key: Union[int, str], default: Optional[Union[int, str]] = ..., version: Optional[int] = ...
|
||||
) -> Any: ...
|
||||
def set(self, key: Union[int, str], value: Any, timeout: Any = ..., version: Optional[int] = ...) -> None: ...
|
||||
def touch(self, key: str, timeout: Any = ..., version: None = ...) -> Any: ...
|
||||
def incr(self, key: Union[int, str], delta: int = ..., version: Optional[int] = ...) -> int: ...
|
||||
|
||||
@@ -12,7 +12,9 @@ class CheckMessage:
|
||||
hint: Any = ...
|
||||
obj: Any = ...
|
||||
id: Any = ...
|
||||
def __init__(self, level: int, msg: str, hint: Optional[str] = ..., obj: Any = ..., id: Optional[str] = ...) -> None: ...
|
||||
def __init__(
|
||||
self, level: int, msg: str, hint: Optional[str] = ..., obj: Any = ..., id: Optional[str] = ...
|
||||
) -> None: ...
|
||||
def __eq__(self, other: Union[CheckMessage, str]) -> bool: ...
|
||||
def is_serious(self, level: int = ...) -> bool: ...
|
||||
def is_silenced(self) -> bool: ...
|
||||
|
||||
@@ -20,7 +20,10 @@ class CheckRegistry:
|
||||
def __init__(self) -> None: ...
|
||||
def register(self, check: Optional[Union[Callable, str]] = ..., *tags: Any, **kwargs: Any) -> Callable: ...
|
||||
def run_checks(
|
||||
self, app_configs: Optional[List[AppConfig]] = ..., tags: Optional[List[str]] = ..., include_deployment_checks: bool = ...
|
||||
self,
|
||||
app_configs: Optional[List[AppConfig]] = ...,
|
||||
tags: Optional[List[str]] = ...,
|
||||
include_deployment_checks: bool = ...,
|
||||
) -> Union[List[CheckMessage], List[int], List[str]]: ...
|
||||
def tag_exists(self, tag: str, include_deployment_checks: bool = ...) -> bool: ...
|
||||
def tags_available(self, deployment_checks: bool = ...) -> Set[str]: ...
|
||||
|
||||
@@ -42,7 +42,9 @@ class ValidationError(Exception):
|
||||
str,
|
||||
],
|
||||
code: Optional[str] = ...,
|
||||
params: Optional[Union[Dict[str, Union[Tuple[str], Type[Model], Model, str]], Dict[str, Union[int, str]]]] = ...,
|
||||
params: Optional[
|
||||
Union[Dict[str, Union[Tuple[str], Type[Model], Model, str]], Dict[str, Union[int, str]]]
|
||||
] = ...,
|
||||
) -> None: ...
|
||||
@property
|
||||
def message_dict(self) -> Dict[str, List[str]]: ...
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
from typing import Any, Optional
|
||||
|
||||
def file_move_safe(old_file_name: str, new_file_name: str, chunk_size: int = ..., allow_overwrite: bool = ...) -> None: ...
|
||||
def file_move_safe(
|
||||
old_file_name: str, new_file_name: str, chunk_size: int = ..., allow_overwrite: bool = ...
|
||||
) -> None: ...
|
||||
|
||||
@@ -25,7 +25,12 @@ class TemporaryUploadedFile(UploadedFile):
|
||||
file: tempfile._TemporaryFileWrapper
|
||||
mode: str
|
||||
def __init__(
|
||||
self, name: str, content_type: str, size: int, charset: Optional[str], content_type_extra: Optional[Dict[Any, Any]] = ...
|
||||
self,
|
||||
name: str,
|
||||
content_type: str,
|
||||
size: int,
|
||||
charset: Optional[str],
|
||||
content_type_extra: Optional[Dict[Any, Any]] = ...,
|
||||
) -> None: ...
|
||||
def temporary_file_path(self) -> str: ...
|
||||
def close(self) -> None: ...
|
||||
|
||||
@@ -40,7 +40,9 @@ class OutputWrapper(TextIOBase):
|
||||
def style_func(self, style_func: Any): ...
|
||||
style_func: Any = ...
|
||||
ending: str = ...
|
||||
def __init__(self, out: Union[StringIO, TextIOWrapper], style_func: Optional[Callable] = ..., ending: str = ...) -> None: ...
|
||||
def __init__(
|
||||
self, out: Union[StringIO, TextIOWrapper], style_func: Optional[Callable] = ..., ending: str = ...
|
||||
) -> None: ...
|
||||
def __getattr__(self, name: str) -> Callable: ...
|
||||
def isatty(self) -> bool: ...
|
||||
def write(self, msg: str, style_func: Optional[Callable] = ..., ending: Optional[str] = ...) -> None: ...
|
||||
@@ -55,7 +57,9 @@ class BaseCommand:
|
||||
stdout: django.core.management.base.OutputWrapper = ...
|
||||
stderr: django.core.management.base.OutputWrapper = ...
|
||||
style: django.core.management.color.Style = ...
|
||||
def __init__(self, stdout: Optional[StringIO] = ..., stderr: Optional[StringIO] = ..., no_color: bool = ...) -> None: ...
|
||||
def __init__(
|
||||
self, stdout: Optional[StringIO] = ..., stderr: Optional[StringIO] = ..., no_color: bool = ...
|
||||
) -> None: ...
|
||||
def get_version(self) -> str: ...
|
||||
def create_parser(self, prog_name: str, subcommand: str) -> CommandParser: ...
|
||||
def add_arguments(self, parser: CommandParser) -> None: ...
|
||||
|
||||
@@ -14,5 +14,7 @@ class Command(BaseCommand):
|
||||
interactive: Any = ...
|
||||
def handle(self, *args: Any, **options: Any) -> None: ...
|
||||
start: Any = ...
|
||||
def migration_progress_callback(self, action: str, migration: Optional[Migration] = ..., fake: bool = ...) -> None: ...
|
||||
def migration_progress_callback(
|
||||
self, action: str, migration: Optional[Migration] = ..., fake: bool = ...
|
||||
) -> None: ...
|
||||
def sync_apps(self, connection: DatabaseWrapper, app_labels: Set[str]) -> None: ...
|
||||
|
||||
@@ -4,7 +4,11 @@ from django.core.management.color import Style
|
||||
from django.db.backends.sqlite3.base import DatabaseWrapper
|
||||
|
||||
def sql_flush(
|
||||
style: Style, connection: DatabaseWrapper, only_django: bool = ..., reset_sequences: bool = ..., allow_cascade: bool = ...
|
||||
style: Style,
|
||||
connection: DatabaseWrapper,
|
||||
only_django: bool = ...,
|
||||
reset_sequences: bool = ...,
|
||||
allow_cascade: bool = ...,
|
||||
) -> List[str]: ...
|
||||
def emit_pre_migrate_signal(verbosity: int, interactive: bool, db: str, **kwargs: Any) -> None: ...
|
||||
def emit_post_migrate_signal(verbosity: int, interactive: bool, db: str, **kwargs: Any) -> None: ...
|
||||
|
||||
@@ -36,7 +36,10 @@ class Page(collections.abc.Sequence):
|
||||
number: int = ...
|
||||
paginator: django.core.paginator.Paginator = ...
|
||||
def __init__(
|
||||
self, object_list: Union[List[Dict[str, str]], List[Model], List[int], QuerySet, str], number: int, paginator: Paginator
|
||||
self,
|
||||
object_list: Union[List[Dict[str, str]], List[Model], List[int], QuerySet, str],
|
||||
number: int,
|
||||
paginator: Paginator,
|
||||
) -> None: ...
|
||||
def __len__(self) -> int: ...
|
||||
def __getitem__(self, index: Union[int, str]) -> Union[Model, str]: ...
|
||||
|
||||
@@ -77,7 +77,9 @@ class DeserializedObject:
|
||||
def save(self, save_m2m: bool = ..., using: Optional[str] = ..., **kwargs: Any) -> None: ...
|
||||
|
||||
def build_instance(Model: Type[Model], data: Dict[str, Optional[Union[date, int, str, UUID]]], db: str) -> Model: ...
|
||||
def deserialize_m2m_values(field: ManyToManyField, field_value: Union[List[List[str]], List[int]], using: str) -> List[int]: ...
|
||||
def deserialize_m2m_values(
|
||||
field: ManyToManyField, field_value: Union[List[List[str]], List[int]], using: str
|
||||
) -> List[int]: ...
|
||||
def deserialize_fk_value(
|
||||
field: ForeignKey, field_value: Optional[Union[List[str], Tuple[str], int, str]], using: str
|
||||
) -> Optional[Union[int, str, UUID]]: ...
|
||||
|
||||
@@ -50,7 +50,9 @@ class EmailValidator:
|
||||
domain_regex: Any = ...
|
||||
literal_regex: Any = ...
|
||||
domain_whitelist: Any = ...
|
||||
def __init__(self, message: Optional[str] = ..., code: Optional[str] = ..., whitelist: Optional[List[str]] = ...) -> None: ...
|
||||
def __init__(
|
||||
self, message: Optional[str] = ..., code: Optional[str] = ..., whitelist: Optional[List[str]] = ...
|
||||
) -> None: ...
|
||||
def __call__(self, value: Optional[str]) -> None: ...
|
||||
def validate_domain_part(self, domain_part: str) -> bool: ...
|
||||
def __eq__(self, other: EmailValidator) -> bool: ...
|
||||
@@ -68,7 +70,9 @@ def validate_ipv46_address(value: str) -> None: ...
|
||||
ip_address_validator_map: Any
|
||||
|
||||
def ip_address_validators(protocol: str, unpack_ipv4: bool) -> Any: ...
|
||||
def int_list_validator(sep: str = ..., message: None = ..., code: str = ..., allow_negative: bool = ...) -> RegexValidator: ...
|
||||
def int_list_validator(
|
||||
sep: str = ..., message: None = ..., code: str = ..., allow_negative: bool = ...
|
||||
) -> RegexValidator: ...
|
||||
|
||||
validate_comma_separated_integer_list: Any
|
||||
|
||||
@@ -76,7 +80,9 @@ class BaseValidator:
|
||||
message: Any = ...
|
||||
code: str = ...
|
||||
limit_value: bool = ...
|
||||
def __init__(self, limit_value: Optional[Union[datetime, Decimal, float, str]], message: Optional[str] = ...) -> None: ...
|
||||
def __init__(
|
||||
self, limit_value: Optional[Union[datetime, Decimal, float, str]], message: Optional[str] = ...
|
||||
) -> None: ...
|
||||
def __call__(self, value: Union[bytes, datetime, Decimal, float, str]) -> None: ...
|
||||
def __eq__(self, other: BaseValidator) -> bool: ...
|
||||
def compare(self, a: bool, b: bool) -> bool: ...
|
||||
|
||||
@@ -45,7 +45,9 @@ class BaseDatabaseWrapper:
|
||||
features: Any = ...
|
||||
introspection: Any = ...
|
||||
validation: Any = ...
|
||||
def __init__(self, settings_dict: Dict[str, Dict[str, str]], alias: str = ..., allow_thread_sharing: bool = ...) -> None: ...
|
||||
def __init__(
|
||||
self, settings_dict: Dict[str, Dict[str, str]], alias: str = ..., allow_thread_sharing: bool = ...
|
||||
) -> None: ...
|
||||
def ensure_timezone(self) -> bool: ...
|
||||
def timezone(self): ...
|
||||
def timezone_name(self): ...
|
||||
|
||||
@@ -7,8 +7,12 @@ TEST_DATABASE_PREFIX: str
|
||||
class BaseDatabaseCreation:
|
||||
connection: django.db.backends.sqlite3.base.DatabaseWrapper = ...
|
||||
def __init__(self, connection: BaseDatabaseWrapper) -> None: ...
|
||||
def create_test_db(self, verbosity: int = ..., autoclobber: bool = ..., serialize: bool = ..., keepdb: bool = ...) -> str: ...
|
||||
def set_as_test_mirror(self, primary_settings_dict: Dict[str, Optional[Union[Dict[str, None], int, str]]]) -> None: ...
|
||||
def create_test_db(
|
||||
self, verbosity: int = ..., autoclobber: bool = ..., serialize: bool = ..., keepdb: bool = ...
|
||||
) -> str: ...
|
||||
def set_as_test_mirror(
|
||||
self, primary_settings_dict: Dict[str, Optional[Union[Dict[str, None], int, str]]]
|
||||
) -> None: ...
|
||||
def serialize_db_to_string(self) -> str: ...
|
||||
def deserialize_db_from_string(self, data: str) -> None: ...
|
||||
def clone_test_db(self, suffix: Any, verbosity: int = ..., autoclobber: bool = ..., keepdb: bool = ...) -> None: ...
|
||||
|
||||
@@ -17,8 +17,12 @@ class DatabaseIntrospection(BaseDatabaseIntrospection):
|
||||
data_types_reverse: Any = ...
|
||||
def get_table_list(self, cursor: CursorWrapper) -> List[TableInfo]: ...
|
||||
def get_table_description(self, cursor: CursorWrapper, table_name: str) -> List[FieldInfo]: ...
|
||||
def get_sequences(self, cursor: CursorWrapper, table_name: str, table_fields: List[Field] = ...) -> List[Dict[str, str]]: ...
|
||||
def get_sequences(
|
||||
self, cursor: CursorWrapper, table_name: str, table_fields: List[Field] = ...
|
||||
) -> List[Dict[str, str]]: ...
|
||||
def get_relations(self, cursor: CursorWrapper, table_name: str) -> Dict[str, Tuple[str, str]]: ...
|
||||
def get_key_columns(self, cursor: CursorWrapper, table_name: str) -> List[Tuple[str, str, str]]: ...
|
||||
def get_primary_key_column(self, cursor: CursorWrapper, table_name: str) -> Optional[str]: ...
|
||||
def get_constraints(self, cursor: CursorWrapper, table_name: str) -> Dict[str, Dict[str, Union[List[str], bool]]]: ...
|
||||
def get_constraints(
|
||||
self, cursor: CursorWrapper, table_name: str
|
||||
) -> Dict[str, Dict[str, Union[List[str], bool]]]: ...
|
||||
|
||||
@@ -16,7 +16,9 @@ class DatabaseOperations(BaseDatabaseOperations):
|
||||
cast_char_field_without_max_length: str = ...
|
||||
cast_data_types: Any = ...
|
||||
explain_prefix: str = ...
|
||||
def bulk_batch_size(self, fields: Union[List[Field], List[str], ImmutableList], objs: Union[List[Model], range]) -> int: ...
|
||||
def bulk_batch_size(
|
||||
self, fields: Union[List[Field], List[str], ImmutableList], objs: Union[List[Model], range]
|
||||
) -> int: ...
|
||||
def check_expression_support(self, expression: Union[BaseExpression, SQLiteNumericMixin]) -> None: ...
|
||||
def date_extract_sql(self, lookup_type: str, field_name: str) -> str: ...
|
||||
def date_interval_sql(self, timedelta: timedelta) -> str: ...
|
||||
@@ -54,12 +56,16 @@ class DatabaseOperations(BaseDatabaseOperations):
|
||||
self, value: Optional[Union[time, str]], expression: Expression, connection: DatabaseWrapper
|
||||
) -> Optional[time]: ...
|
||||
def get_decimalfield_converter(self, expression: Expression) -> Callable: ...
|
||||
def convert_uuidfield_value(self, value: Optional[str], expression: Col, connection: DatabaseWrapper) -> Optional[UUID]: ...
|
||||
def convert_uuidfield_value(
|
||||
self, value: Optional[str], expression: Col, connection: DatabaseWrapper
|
||||
) -> Optional[UUID]: ...
|
||||
def convert_booleanfield_value(
|
||||
self, value: Optional[int], expression: Expression, connection: DatabaseWrapper
|
||||
) -> Optional[bool]: ...
|
||||
def bulk_insert_sql(
|
||||
self, fields: Union[List[None], List[Field], ImmutableList], placeholder_rows: Union[List[Any], Tuple[Tuple[str]]]
|
||||
self,
|
||||
fields: Union[List[None], List[Field], ImmutableList],
|
||||
placeholder_rows: Union[List[Any], Tuple[Tuple[str]]],
|
||||
) -> str: ...
|
||||
def combine_expression(self, connector: str, sub_expressions: List[str]) -> str: ...
|
||||
def combine_duration_expression(self, connector: str, sub_expressions: List[str]) -> str: ...
|
||||
|
||||
@@ -35,5 +35,7 @@ def typecast_timestamp(s: Optional[str]) -> Optional[date]: ...
|
||||
def rev_typecast_decimal(d: Decimal) -> str: ...
|
||||
def split_identifier(identifier: str) -> Tuple[str, str]: ...
|
||||
def truncate_name(identifier: str, length: Optional[int] = ..., hash_len: int = ...) -> str: ...
|
||||
def format_number(value: Optional[Decimal], max_digits: Optional[int], decimal_places: Optional[int]) -> Optional[str]: ...
|
||||
def format_number(
|
||||
value: Optional[Decimal], max_digits: Optional[int], decimal_places: Optional[int]
|
||||
) -> Optional[str]: ...
|
||||
def strip_quotes(table_name: str) -> str: ...
|
||||
|
||||
@@ -28,7 +28,9 @@ class MigrationAutodetector:
|
||||
def only_relation_agnostic_fields(
|
||||
self, fields: List[Tuple[str, Field]]
|
||||
) -> List[Tuple[str, List[Any], Dict[str, Union[Callable, int, str]]]]: ...
|
||||
def check_dependency(self, operation: Operation, dependency: Tuple[str, str, Optional[str], Union[bool, str]]) -> bool: ...
|
||||
def check_dependency(
|
||||
self, operation: Operation, dependency: Tuple[str, str, Optional[str], Union[bool, str]]
|
||||
) -> bool: ...
|
||||
def add_operation(
|
||||
self,
|
||||
app_label: str,
|
||||
|
||||
@@ -37,4 +37,6 @@ class MigrationExecutor:
|
||||
) -> ProjectState: ...
|
||||
def unapply_migration(self, state: ProjectState, migration: Migration, fake: bool = ...) -> ProjectState: ...
|
||||
def check_replacements(self) -> None: ...
|
||||
def detect_soft_applied(self, project_state: Optional[ProjectState], migration: Migration) -> Tuple[bool, ProjectState]: ...
|
||||
def detect_soft_applied(
|
||||
self, project_state: Optional[ProjectState], migration: Migration
|
||||
) -> Tuple[bool, ProjectState]: ...
|
||||
|
||||
@@ -2,7 +2,12 @@
|
||||
#
|
||||
# NOTE: This dynamically typed stub was automatically generated by stubgen.
|
||||
|
||||
from .fields import AddField as AddField, AlterField as AlterField, RemoveField as RemoveField, RenameField as RenameField
|
||||
from .fields import (
|
||||
AddField as AddField,
|
||||
AlterField as AlterField,
|
||||
RemoveField as RemoveField,
|
||||
RenameField as RenameField,
|
||||
)
|
||||
from .models import (
|
||||
AddIndex as AddIndex,
|
||||
AlterIndexTogether as AlterIndexTogether,
|
||||
|
||||
@@ -87,7 +87,9 @@ class ModelOptionOperation(ModelOperation):
|
||||
def reduce(self, operation: Operation, in_between: List[DeleteModel], app_label: str = ...) -> bool: ...
|
||||
|
||||
class FieldRelatedOptionOperation(ModelOptionOperation):
|
||||
def reduce(self, operation: Operation, in_between: List[Any], app_label: str = ...) -> Union[List[Operation], bool]: ...
|
||||
def reduce(
|
||||
self, operation: Operation, in_between: List[Any], app_label: str = ...
|
||||
) -> Union[List[Operation], bool]: ...
|
||||
|
||||
class AlterUniqueTogether(FieldRelatedOptionOperation):
|
||||
option_name: str = ...
|
||||
|
||||
@@ -10,7 +10,10 @@ class MigrationQuestioner:
|
||||
specified_apps: Set[Any] = ...
|
||||
dry_run: None = ...
|
||||
def __init__(
|
||||
self, defaults: Optional[Dict[str, bool]] = ..., specified_apps: Optional[Set[str]] = ..., dry_run: Optional[bool] = ...
|
||||
self,
|
||||
defaults: Optional[Dict[str, bool]] = ...,
|
||||
specified_apps: Optional[Set[str]] = ...,
|
||||
dry_run: Optional[bool] = ...,
|
||||
) -> None: ...
|
||||
def ask_initial(self, app_label: str) -> bool: ...
|
||||
def ask_not_null_addition(self, field_name: str, model_name: str) -> None: ...
|
||||
|
||||
@@ -75,7 +75,9 @@ class StateApps:
|
||||
ready: bool
|
||||
real_models: List[django.db.migrations.state.ModelState]
|
||||
stored_app_configs: List[Any]
|
||||
def __init__(self, real_apps: List[str], models: Dict[Tuple[str, str], ModelState], ignore_swappable: bool = ...) -> None: ...
|
||||
def __init__(
|
||||
self, real_apps: List[str], models: Dict[Tuple[str, str], ModelState], ignore_swappable: bool = ...
|
||||
) -> None: ...
|
||||
def bulk_update(self) -> Iterator[None]: ...
|
||||
def clone(self) -> StateApps: ...
|
||||
def render_multiple(self, model_states: List[ModelState]) -> None: ...
|
||||
|
||||
@@ -3,4 +3,6 @@ from typing import Any, Dict, Iterator, List, Optional, Set
|
||||
from django.db.migrations.operations.base import Operation
|
||||
|
||||
def topological_sort_as_sets(dependency_graph: Dict[Operation, Set[Operation]]) -> Iterator[Set[Operation]]: ...
|
||||
def stable_topological_sort(l: List[Operation], dependency_graph: Dict[Operation, Set[Operation]]) -> List[Operation]: ...
|
||||
def stable_topological_sort(
|
||||
l: List[Operation], dependency_graph: Dict[Operation, Set[Operation]]
|
||||
) -> List[Operation]: ...
|
||||
|
||||
@@ -20,7 +20,12 @@ class Aggregate(Func):
|
||||
def get_source_expressions(self) -> List[Union[Combinable, WhereNode]]: ...
|
||||
def set_source_expressions(self, exprs: List[Union[Expression, WhereNode]]) -> None: ...
|
||||
def resolve_expression(
|
||||
self, query: Query = ..., allow_joins: bool = ..., reuse: None = ..., summarize: bool = ..., for_save: bool = ...
|
||||
self,
|
||||
query: Query = ...,
|
||||
allow_joins: bool = ...,
|
||||
reuse: None = ...,
|
||||
summarize: bool = ...,
|
||||
for_save: bool = ...,
|
||||
) -> Aggregate: ...
|
||||
@property
|
||||
def default_alias(self) -> str: ...
|
||||
|
||||
@@ -11,7 +11,9 @@ class Deferred: ...
|
||||
|
||||
DEFERRED: Any
|
||||
|
||||
def subclass_exception(name: str, bases: Tuple[Type[Exception]], module: str, attached_to: Type[Model]) -> Type[Exception]: ...
|
||||
def subclass_exception(
|
||||
name: str, bases: Tuple[Type[Exception]], module: str, attached_to: Type[Model]
|
||||
) -> Type[Exception]: ...
|
||||
|
||||
class ModelBase(type):
|
||||
def __new__(
|
||||
|
||||
@@ -16,7 +16,9 @@ from django.db.models.sql.where import WhereNode
|
||||
from django.utils.tree import Node
|
||||
|
||||
class SQLiteNumericMixin:
|
||||
def as_sqlite(self, compiler: SQLCompiler, connection: DatabaseWrapper, **extra_context: Any) -> Tuple[str, List[float]]: ...
|
||||
def as_sqlite(
|
||||
self, compiler: SQLCompiler, connection: DatabaseWrapper, **extra_context: Any
|
||||
) -> Tuple[str, List[float]]: ...
|
||||
|
||||
class Combinable:
|
||||
ADD: str = ...
|
||||
@@ -112,7 +114,9 @@ class DurationExpression(CombinedExpression):
|
||||
def compile(
|
||||
self, side: Expression, compiler: SQLCompiler, connection: DatabaseWrapper
|
||||
) -> Tuple[str, Union[List[datetime], List[int]]]: ...
|
||||
def as_sql(self, compiler: SQLCompiler, connection: DatabaseWrapper) -> Tuple[str, Union[List[datetime], List[int]]]: ...
|
||||
def as_sql(
|
||||
self, compiler: SQLCompiler, connection: DatabaseWrapper
|
||||
) -> Tuple[str, Union[List[datetime], List[int]]]: ...
|
||||
|
||||
class TemporalSubtraction(CombinedExpression):
|
||||
output_field: Any = ...
|
||||
@@ -229,7 +233,12 @@ class Ref(Expression):
|
||||
def get_source_expressions(self) -> Union[List[Expression], List[SQLiteNumericMixin]]: ...
|
||||
def set_source_expressions(self, exprs: Any) -> None: ...
|
||||
def resolve_expression(
|
||||
self, query: Query = ..., allow_joins: bool = ..., reuse: None = ..., summarize: bool = ..., for_save: bool = ...
|
||||
self,
|
||||
query: Query = ...,
|
||||
allow_joins: bool = ...,
|
||||
reuse: None = ...,
|
||||
summarize: bool = ...,
|
||||
for_save: bool = ...,
|
||||
) -> Ref: ...
|
||||
def relabeled_clone(self, relabels: Dict[Optional[str], str]) -> Ref: ...
|
||||
def as_sql(self, compiler: SQLCompiler, connection: DatabaseWrapper) -> Tuple[str, List[Any]]: ...
|
||||
@@ -273,7 +282,9 @@ class Case(Expression):
|
||||
cases: Any = ...
|
||||
default: Any = ...
|
||||
extra: Any = ...
|
||||
def __init__(self, *cases: Any, default: Optional[Any] = ..., output_field: Optional[Any] = ..., **extra: Any) -> None: ...
|
||||
def __init__(
|
||||
self, *cases: Any, default: Optional[Any] = ..., output_field: Optional[Any] = ..., **extra: Any
|
||||
) -> None: ...
|
||||
def get_source_expressions(self) -> List[Expression]: ...
|
||||
def set_source_expressions(self, exprs: List[Expression]) -> None: ...
|
||||
def resolve_expression(
|
||||
|
||||
@@ -87,7 +87,9 @@ class Field(RegisterLookupMixin):
|
||||
error_messages: None = ...,
|
||||
) -> None: ...
|
||||
def check(self, **kwargs: Any) -> List[Any]: ...
|
||||
def get_col(self, alias: str, output_field: Optional[Union[Field, reverse_related.ForeignObjectRel]] = ...) -> Col: ...
|
||||
def get_col(
|
||||
self, alias: str, output_field: Optional[Union[Field, reverse_related.ForeignObjectRel]] = ...
|
||||
) -> Col: ...
|
||||
def cached_col(self) -> Col: ...
|
||||
def select_format(
|
||||
self, compiler: SQLCompiler, sql: str, params: List[Union[int, str]]
|
||||
@@ -162,7 +164,9 @@ class AutoField(Field):
|
||||
def to_python(self, value: Union[int, str]) -> int: ...
|
||||
def rel_db_type(self, connection: DatabaseWrapper) -> str: ...
|
||||
def validate(self, value: Any, model_instance: Any) -> None: ...
|
||||
def get_db_prep_value(self, value: Union[int, str], connection: DatabaseWrapper, prepared: bool = ...) -> Union[int, str]: ...
|
||||
def get_db_prep_value(
|
||||
self, value: Union[int, str], connection: DatabaseWrapper, prepared: bool = ...
|
||||
) -> Union[int, str]: ...
|
||||
def get_prep_value(self, value: Optional[Union[int, str]]) -> Optional[int]: ...
|
||||
def contribute_to_class(self, cls: Type[Model], name: str, **kwargs: Any) -> None: ...
|
||||
def formfield(self, **kwargs: Any) -> None: ...
|
||||
@@ -206,7 +210,12 @@ class DateField(DateTimeCheckMixin, Field):
|
||||
default_error_messages: Any = ...
|
||||
description: Any = ...
|
||||
def __init__(
|
||||
self, verbose_name: Optional[str] = ..., name: None = ..., auto_now: bool = ..., auto_now_add: bool = ..., **kwargs: Any
|
||||
self,
|
||||
verbose_name: Optional[str] = ...,
|
||||
name: None = ...,
|
||||
auto_now: bool = ...,
|
||||
auto_now_add: bool = ...,
|
||||
**kwargs: Any
|
||||
) -> None: ...
|
||||
def deconstruct(self) -> Tuple[Optional[str], str, List[Any], Dict[str, Union[Callable, int, str]]]: ...
|
||||
def get_internal_type(self) -> str: ...
|
||||
@@ -214,7 +223,9 @@ class DateField(DateTimeCheckMixin, Field):
|
||||
def pre_save(self, model_instance: Model, add: bool) -> Optional[Union[date, CombinedExpression]]: ...
|
||||
def contribute_to_class(self, cls: Type[Model], name: str, **kwargs: Any) -> None: ...
|
||||
def get_prep_value(self, value: Optional[Union[date, str]]) -> Optional[date]: ...
|
||||
def get_db_prep_value(self, value: Optional[date], connection: DatabaseWrapper, prepared: bool = ...) -> Optional[str]: ...
|
||||
def get_db_prep_value(
|
||||
self, value: Optional[date], connection: DatabaseWrapper, prepared: bool = ...
|
||||
) -> Optional[str]: ...
|
||||
def value_to_string(self, obj: Model) -> str: ...
|
||||
def formfield(self, **kwargs: Any) -> Field: ...
|
||||
|
||||
@@ -343,7 +354,9 @@ class GenericIPAddressField(Field):
|
||||
def deconstruct(self): ...
|
||||
def get_internal_type(self): ...
|
||||
def to_python(self, value: Union[Callable, int, str]) -> str: ...
|
||||
def get_db_prep_value(self, value: Optional[str], connection: DatabaseWrapper, prepared: bool = ...) -> Optional[str]: ...
|
||||
def get_db_prep_value(
|
||||
self, value: Optional[str], connection: DatabaseWrapper, prepared: bool = ...
|
||||
) -> Optional[str]: ...
|
||||
def get_prep_value(self, value: Optional[str]) -> Optional[str]: ...
|
||||
|
||||
class NullBooleanField(BooleanField):
|
||||
|
||||
@@ -84,7 +84,9 @@ class ImageField(FileField):
|
||||
**kwargs: Any
|
||||
) -> None: ...
|
||||
def check(self, **kwargs: Any) -> List[Any]: ...
|
||||
def deconstruct(self) -> Tuple[Optional[str], str, List[Any], Dict[str, Union[Callable, bool, FileSystemStorage, str]]]: ...
|
||||
def deconstruct(
|
||||
self
|
||||
) -> Tuple[Optional[str], str, List[Any], Dict[str, Union[Callable, bool, FileSystemStorage, str]]]: ...
|
||||
def contribute_to_class(self, cls: Type[Model], name: str, **kwargs: Any) -> None: ...
|
||||
def update_dimension_fields(self, instance: Model, force: bool = ..., *args: Any, **kwargs: Any) -> None: ...
|
||||
def formfield(self, **kwargs: Any) -> ImageField: ...
|
||||
|
||||
@@ -7,7 +7,16 @@ from django.db.models.base import Model
|
||||
from django.db.models.expressions import Col
|
||||
from django.db.models.fields import Field
|
||||
from django.db.models.fields.related import ForeignObject
|
||||
from django.db.models.lookups import BuiltinLookup, Exact, GreaterThan, GreaterThanOrEqual, In, IsNull, LessThan, LessThanOrEqual
|
||||
from django.db.models.lookups import (
|
||||
BuiltinLookup,
|
||||
Exact,
|
||||
GreaterThan,
|
||||
GreaterThanOrEqual,
|
||||
In,
|
||||
IsNull,
|
||||
LessThan,
|
||||
LessThanOrEqual,
|
||||
)
|
||||
from django.db.models.sql.compiler import SQLCompiler
|
||||
from django.db.models.sql.query import Query
|
||||
|
||||
|
||||
@@ -56,7 +56,9 @@ class ForeignObjectRel(FieldCacheMixin):
|
||||
def get_internal_type(self) -> str: ...
|
||||
@property
|
||||
def db_type(self) -> Callable: ...
|
||||
def get_choices(self, include_blank: bool = ..., blank_choice: List[Tuple[str, str]] = ...) -> List[Tuple[int, str]]: ...
|
||||
def get_choices(
|
||||
self, include_blank: bool = ..., blank_choice: List[Tuple[str, str]] = ...
|
||||
) -> List[Tuple[int, str]]: ...
|
||||
def is_hidden(self) -> bool: ...
|
||||
def get_joining_columns(self) -> Tuple: ...
|
||||
def get_extra_restriction(
|
||||
|
||||
@@ -141,7 +141,9 @@ class TruncBase(TimezoneMixin, Transform):
|
||||
summarize: bool = ...,
|
||||
for_save: bool = ...,
|
||||
) -> TruncBase: ...
|
||||
def convert_value(self, value: datetime, expression: models.functions.TruncBase, connection: DatabaseWrapper) -> datetime: ...
|
||||
def convert_value(
|
||||
self, value: datetime, expression: models.functions.TruncBase, connection: DatabaseWrapper
|
||||
) -> datetime: ...
|
||||
|
||||
class Trunc(TruncBase):
|
||||
contains_aggregate: bool
|
||||
|
||||
@@ -6,7 +6,9 @@ from django.db.models.expressions import Combinable, Expression, Value
|
||||
from django.db.models.sql.compiler import SQLCompiler
|
||||
|
||||
class BytesToCharFieldConversionMixin:
|
||||
def convert_value(self, value: str, expression: BytesToCharFieldConversionMixin, connection: DatabaseWrapper) -> str: ...
|
||||
def convert_value(
|
||||
self, value: str, expression: BytesToCharFieldConversionMixin, connection: DatabaseWrapper
|
||||
) -> str: ...
|
||||
|
||||
class Chr(Transform):
|
||||
contains_aggregate: bool
|
||||
@@ -18,7 +20,9 @@ class Chr(Transform):
|
||||
lookup_name: str = ...
|
||||
def as_mysql(self, compiler: Any, connection: Any): ...
|
||||
def as_oracle(self, compiler: Any, connection: Any): ...
|
||||
def as_sqlite(self, compiler: SQLCompiler, connection: DatabaseWrapper, **extra_context: Any) -> Tuple[str, List[int]]: ...
|
||||
def as_sqlite(
|
||||
self, compiler: SQLCompiler, connection: DatabaseWrapper, **extra_context: Any
|
||||
) -> Tuple[str, List[int]]: ...
|
||||
|
||||
class ConcatPair(Func):
|
||||
contains_aggregate: bool
|
||||
@@ -54,7 +58,9 @@ class Left(Func):
|
||||
arity: int = ...
|
||||
def __init__(self, expression: str, length: Union[Value, int], **extra: Any) -> None: ...
|
||||
def get_substr(self) -> Substr: ...
|
||||
def use_substr(self, compiler: SQLCompiler, connection: DatabaseWrapper, **extra_context: Any) -> Tuple[str, List[int]]: ...
|
||||
def use_substr(
|
||||
self, compiler: SQLCompiler, connection: DatabaseWrapper, **extra_context: Any
|
||||
) -> Tuple[str, List[int]]: ...
|
||||
as_oracle: Any = ...
|
||||
as_sqlite: Any = ...
|
||||
|
||||
@@ -111,7 +117,9 @@ class Ord(Transform):
|
||||
lookup_name: str = ...
|
||||
output_field: Any = ...
|
||||
def as_mysql(self, compiler: Any, connection: Any, **extra_context: Any): ...
|
||||
def as_sqlite(self, compiler: SQLCompiler, connection: DatabaseWrapper, **extra_context: Any) -> Tuple[str, List[Any]]: ...
|
||||
def as_sqlite(
|
||||
self, compiler: SQLCompiler, connection: DatabaseWrapper, **extra_context: Any
|
||||
) -> Tuple[str, List[Any]]: ...
|
||||
|
||||
class Repeat(BytesToCharFieldConversionMixin, Func):
|
||||
contains_aggregate: bool
|
||||
|
||||
@@ -66,7 +66,9 @@ class FieldGetDbPrepValueMixin:
|
||||
class FieldGetDbPrepValueIterableMixin(FieldGetDbPrepValueMixin):
|
||||
get_db_prep_lookup_value_is_iterable: bool = ...
|
||||
def get_prep_lookup(self) -> Iterable[Any]: ...
|
||||
def process_rhs(self, compiler: SQLCompiler, connection: DatabaseWrapper) -> Tuple[Union[Tuple[str, str], str], Tuple]: ...
|
||||
def process_rhs(
|
||||
self, compiler: SQLCompiler, connection: DatabaseWrapper
|
||||
) -> Tuple[Union[Tuple[str, str], str], Tuple]: ...
|
||||
def resolve_expression_parameter(
|
||||
self, compiler: SQLCompiler, connection: DatabaseWrapper, sql: str, param: Optional[Union[Combinable, int, str]]
|
||||
) -> Tuple[str, List[None]]: ...
|
||||
|
||||
@@ -50,7 +50,9 @@ class Manager(Generic[_T]):
|
||||
def all(self) -> QuerySet[_T]: ...
|
||||
def filter(self, *args: Any, **kwargs: Any) -> QuerySet[_T]: ...
|
||||
def exclude(self, *args: Any, **kwargs: Any) -> QuerySet[_T]: ...
|
||||
def complex_filter(self, filter_obj: Union[Dict[str, datetime], Dict[str, QuerySet], Q, MagicMock]) -> QuerySet[_T]: ...
|
||||
def complex_filter(
|
||||
self, filter_obj: Union[Dict[str, datetime], Dict[str, QuerySet], Q, MagicMock]
|
||||
) -> QuerySet[_T]: ...
|
||||
def union(self, *other_qs: Any, all: bool = ...) -> QuerySet[_T]: ...
|
||||
def intersection(self, *other_qs: Any) -> QuerySet[_T]: ...
|
||||
def difference(self, *other_qs: Any) -> QuerySet[_T]: ...
|
||||
|
||||
@@ -90,7 +90,9 @@ class Options:
|
||||
default_related_name: None = ...
|
||||
def __init__(
|
||||
self,
|
||||
meta: Optional[Type[Union[AbstractBaseUser.Meta, AbstractUser.Meta, PermissionsMixin.Meta, AbstractBaseSession.Meta]]],
|
||||
meta: Optional[
|
||||
Type[Union[AbstractBaseUser.Meta, AbstractUser.Meta, PermissionsMixin.Meta, AbstractBaseSession.Meta]]
|
||||
],
|
||||
app_label: Optional[str] = ...,
|
||||
) -> None: ...
|
||||
@property
|
||||
|
||||
@@ -76,7 +76,10 @@ class QuerySet(Generic[_T]):
|
||||
memo: Dict[
|
||||
int,
|
||||
Union[
|
||||
Dict[str, Union[ModelState, int, str]], List[Union[Dict[str, Union[bool, str]], ModelState]], Model, ModelState
|
||||
Dict[str, Union[ModelState, int, str]],
|
||||
List[Union[Dict[str, Union[bool, str]], ModelState]],
|
||||
Model,
|
||||
ModelState,
|
||||
],
|
||||
],
|
||||
) -> QuerySet[_T]: ...
|
||||
@@ -129,7 +132,9 @@ class QuerySet(Generic[_T]):
|
||||
def all(self) -> QuerySet[_T]: ...
|
||||
def filter(self, *args: Any, **kwargs: Any) -> QuerySet[_T]: ...
|
||||
def exclude(self, *args: Any, **kwargs: Any) -> QuerySet[_T]: ...
|
||||
def complex_filter(self, filter_obj: Union[Dict[str, datetime], Dict[str, QuerySet], Q, MagicMock]) -> QuerySet[_T]: ...
|
||||
def complex_filter(
|
||||
self, filter_obj: Union[Dict[str, datetime], Dict[str, QuerySet], Q, MagicMock]
|
||||
) -> QuerySet[_T]: ...
|
||||
def union(self, *other_qs: Any, all: bool = ...) -> QuerySet[_T]: ...
|
||||
def intersection(self, *other_qs: Any) -> QuerySet[_T]: ...
|
||||
def difference(self, *other_qs: Any) -> QuerySet[_T]: ...
|
||||
@@ -237,7 +242,9 @@ class RelatedPopulator:
|
||||
def populate(
|
||||
self,
|
||||
row: Union[
|
||||
List[Optional[Union[date, int, str]]], List[Union[date, Decimal, float, str]], Tuple[Union[int, str], str, int]
|
||||
List[Optional[Union[date, int, str]]],
|
||||
List[Union[date, Decimal, float, str]],
|
||||
Tuple[Union[int, str], str, int],
|
||||
],
|
||||
from_obj: Model,
|
||||
) -> None: ...
|
||||
|
||||
@@ -60,7 +60,11 @@ class RegisterLookupMixin:
|
||||
def get_transform(self, lookup_name: str) -> Optional[Type[Transform]]: ...
|
||||
@staticmethod
|
||||
def merge_dicts(
|
||||
dicts: List[Dict[str, Type[Union[TimezoneMixin, FieldGetDbPrepValueMixin, IntegerFieldFloatRounding, Lookup, Transform]]]]
|
||||
dicts: List[
|
||||
Dict[
|
||||
str, Type[Union[TimezoneMixin, FieldGetDbPrepValueMixin, IntegerFieldFloatRounding, Lookup, Transform]]
|
||||
]
|
||||
]
|
||||
) -> Dict[str, Type[Union[TimezoneMixin, FieldGetDbPrepValueMixin, Lookup, Transform]]]: ...
|
||||
@classmethod
|
||||
def register_lookup(
|
||||
@@ -70,7 +74,9 @@ class RegisterLookupMixin:
|
||||
def select_related_descend(
|
||||
field: Field,
|
||||
restricted: bool,
|
||||
requested: Optional[Union[Dict[str, Dict[str, Dict[str, Dict[str, Dict[str, Dict[str, Dict[str, Dict[Any, Any]]]]]]]], bool]],
|
||||
requested: Optional[
|
||||
Union[Dict[str, Dict[str, Dict[str, Dict[str, Dict[str, Dict[str, Dict[str, Dict[Any, Any]]]]]]]], bool]
|
||||
],
|
||||
load_fields: Optional[Set[str]],
|
||||
reverse: bool = ...,
|
||||
) -> bool: ...
|
||||
|
||||
@@ -41,7 +41,9 @@ class SQLCompiler:
|
||||
select: List[Tuple[Union[BaseExpression, SQLiteNumericMixin], Tuple[str, List[float]], Optional[str]]],
|
||||
order_by: List[Tuple[OrderBy, Tuple[str, List[Union[int, str]], bool]]],
|
||||
) -> List[Tuple[str, List[float]]]: ...
|
||||
def collapse_group_by(self, expressions: List[Expression], having: Union[List[Expression], Tuple]) -> List[Expression]: ...
|
||||
def collapse_group_by(
|
||||
self, expressions: List[Expression], having: Union[List[Expression], Tuple]
|
||||
) -> List[Expression]: ...
|
||||
def get_select(
|
||||
self
|
||||
) -> Tuple[
|
||||
@@ -56,7 +58,9 @@ class SQLCompiler:
|
||||
select: List[Tuple[Union[Expression, SQLiteNumericMixin], Tuple[str, List[float]], Optional[str]]],
|
||||
) -> List[Tuple[OrderBy, Tuple[str, List[Any]], None]]: ...
|
||||
def quote_name_unless_alias(self, name: str) -> str: ...
|
||||
def compile(self, node: Any, select_format: Any = ...) -> Tuple[str, Union[List[Optional[int]], Tuple[int, int]]]: ...
|
||||
def compile(
|
||||
self, node: Any, select_format: Any = ...
|
||||
) -> Tuple[str, Union[List[Optional[int]], Tuple[int, int]]]: ...
|
||||
def get_combinator_sql(self, combinator: str, all: bool) -> Tuple[List[str], Union[List[int], List[str]]]: ...
|
||||
def as_sql(self, with_limits: bool = ..., with_col_aliases: bool = ...) -> Any: ...
|
||||
def get_default_columns(
|
||||
|
||||
@@ -46,9 +46,13 @@ class RawQuery:
|
||||
class Query:
|
||||
base_table: str
|
||||
related_ids: None
|
||||
related_updates: Dict[Type[django.db.models.base.Model], List[Tuple[django.db.models.fields.Field, None, Union[int, str]]]]
|
||||
related_updates: Dict[
|
||||
Type[django.db.models.base.Model], List[Tuple[django.db.models.fields.Field, None, Union[int, str]]]
|
||||
]
|
||||
values: List[
|
||||
Tuple[django.db.models.fields.Field, Optional[Type[django.db.models.base.Model]], django.db.models.aggregates.Max]
|
||||
Tuple[
|
||||
django.db.models.fields.Field, Optional[Type[django.db.models.base.Model]], django.db.models.aggregates.Max
|
||||
]
|
||||
]
|
||||
alias_prefix: str = ...
|
||||
subq_aliases: frozenset = ...
|
||||
@@ -75,7 +79,9 @@ class Query:
|
||||
select_for_update_nowait: bool = ...
|
||||
select_for_update_skip_locked: bool = ...
|
||||
select_for_update_of: Tuple = ...
|
||||
select_related: Union[Dict[str, Dict[str, Dict[str, Dict[str, Dict[str, Dict[str, Dict[str, Dict[Any, Any]]]]]]]], bool] = ...
|
||||
select_related: Union[
|
||||
Dict[str, Dict[str, Dict[str, Dict[str, Dict[str, Dict[str, Dict[str, Dict[Any, Any]]]]]]]], bool
|
||||
] = ...
|
||||
max_depth: int = ...
|
||||
values_select: Tuple = ...
|
||||
annotation_select_mask: Optional[Set[str]] = ...
|
||||
@@ -103,7 +109,10 @@ class Query:
|
||||
memo: Dict[
|
||||
int,
|
||||
Union[
|
||||
Dict[str, Union[ModelState, int, str]], List[Union[Dict[str, Union[bool, str]], ModelState]], Model, ModelState
|
||||
Dict[str, Union[ModelState, int, str]],
|
||||
List[Union[Dict[str, Union[bool, str]], ModelState]],
|
||||
Model,
|
||||
ModelState,
|
||||
],
|
||||
],
|
||||
) -> Query: ...
|
||||
@@ -146,10 +155,18 @@ class Query:
|
||||
def resolve_expression(self, query: Query, *args: Any, **kwargs: Any) -> Query: ...
|
||||
def as_sql(self, compiler: SQLCompiler, connection: DatabaseWrapper) -> Tuple[str, Tuple]: ...
|
||||
def resolve_lookup_value(self, value: Any, can_reuse: Optional[Set[str]], allow_joins: bool) -> Any: ...
|
||||
def solve_lookup_type(self, lookup: str) -> Union[Tuple[List[str], List[str], bool], Tuple[List[str], Tuple, Expression]]: ...
|
||||
def check_query_object_type(self, value: Union[Model, int, str, UUID], opts: Options, field: FieldCacheMixin) -> None: ...
|
||||
def check_related_objects(self, field: Union[Field, reverse_related.ForeignObjectRel], value: Any, opts: Options) -> None: ...
|
||||
def build_lookup(self, lookups: List[str], lhs: Union[Expression, TextField, MultiColSource], rhs: Any) -> Lookup: ...
|
||||
def solve_lookup_type(
|
||||
self, lookup: str
|
||||
) -> Union[Tuple[List[str], List[str], bool], Tuple[List[str], Tuple, Expression]]: ...
|
||||
def check_query_object_type(
|
||||
self, value: Union[Model, int, str, UUID], opts: Options, field: FieldCacheMixin
|
||||
) -> None: ...
|
||||
def check_related_objects(
|
||||
self, field: Union[Field, reverse_related.ForeignObjectRel], value: Any, opts: Options
|
||||
) -> None: ...
|
||||
def build_lookup(
|
||||
self, lookups: List[str], lhs: Union[Expression, TextField, MultiColSource], rhs: Any
|
||||
) -> Lookup: ...
|
||||
def try_transform(self, lhs: Expression, name: str) -> Transform: ...
|
||||
def build_filter(
|
||||
self,
|
||||
|
||||
@@ -82,7 +82,9 @@ class UpdateQuery(Query):
|
||||
model: Type[django.db.models.base.Model]
|
||||
order_by: Tuple
|
||||
related_ids: Optional[List[int]]
|
||||
related_updates: Dict[Type[django.db.models.base.Model], List[Tuple[django.db.models.fields.Field, None, Union[int, str]]]]
|
||||
related_updates: Dict[
|
||||
Type[django.db.models.base.Model], List[Tuple[django.db.models.fields.Field, None, Union[int, str]]]
|
||||
]
|
||||
select: Tuple
|
||||
select_for_update: bool
|
||||
select_for_update_nowait: bool
|
||||
|
||||
@@ -39,7 +39,9 @@ class WhereNode(tree.Node):
|
||||
|
||||
class NothingNode:
|
||||
contains_aggregate: bool = ...
|
||||
def as_sql(self, compiler: SQLCompiler = ..., connection: Union[DefaultConnectionProxy, DatabaseWrapper] = ...) -> Any: ...
|
||||
def as_sql(
|
||||
self, compiler: SQLCompiler = ..., connection: Union[DefaultConnectionProxy, DatabaseWrapper] = ...
|
||||
) -> Any: ...
|
||||
|
||||
class ExtraWhere:
|
||||
contains_aggregate: bool = ...
|
||||
|
||||
@@ -33,7 +33,9 @@ class ConnectionDoesNotExist(Exception): ...
|
||||
class ConnectionHandler:
|
||||
databases: Dict[str, Dict[str, Optional[Union[Dict[str, Optional[bool]], int, str]]]]
|
||||
def __init__(self, databases: Dict[str, Dict[str, Union[Dict[str, str], str]]] = ...) -> None: ...
|
||||
def databases(self) -> Dict[str, Union[Dict[str, Union[Dict[str, bool], str]], Dict[str, Union[Dict[str, str], str]]]]: ...
|
||||
def databases(
|
||||
self
|
||||
) -> Dict[str, Union[Dict[str, Union[Dict[str, bool], str]], Dict[str, Union[Dict[str, str], str]]]]: ...
|
||||
def ensure_defaults(self, alias: str) -> None: ...
|
||||
def prepare_test_settings(self, alias: str) -> None: ...
|
||||
def __getitem__(self, alias: str) -> BaseDatabaseWrapper: ...
|
||||
@@ -52,4 +54,6 @@ class ConnectionRouter:
|
||||
def allow_relation(self, obj1: Model, obj2: Model, **hints: Any) -> bool: ...
|
||||
def allow_migrate(self, db: str, app_label: str, **hints: Any) -> bool: ...
|
||||
def allow_migrate_model(self, db: str, model: Type[Model]) -> bool: ...
|
||||
def get_migratable_models(self, app_config: AppConfig, db: str, include_auto_created: bool = ...) -> List[Type[Model]]: ...
|
||||
def get_migratable_models(
|
||||
self, app_config: AppConfig, db: str, include_auto_created: bool = ...
|
||||
) -> List[Type[Model]]: ...
|
||||
|
||||
@@ -43,7 +43,9 @@ class BoundField:
|
||||
@property
|
||||
def id_for_label(self) -> str: ...
|
||||
def initial(self) -> Any: ...
|
||||
def build_widget_attrs(self, attrs: Dict[str, str], widget: Optional[Widget] = ...) -> Dict[str, Union[bool, str]]: ...
|
||||
def build_widget_attrs(
|
||||
self, attrs: Dict[str, str], widget: Optional[Widget] = ...
|
||||
) -> Dict[str, Union[bool, str]]: ...
|
||||
|
||||
class BoundWidget:
|
||||
parent_widget: django.forms.widgets.Widget = ...
|
||||
|
||||
@@ -67,7 +67,9 @@ class CharField(Field):
|
||||
localize: bool
|
||||
required: bool
|
||||
show_hidden_initial: bool
|
||||
validators: List[Union[django.core.validators.BaseValidator, django.core.validators.ProhibitNullCharactersValidator]]
|
||||
validators: List[
|
||||
Union[django.core.validators.BaseValidator, django.core.validators.ProhibitNullCharactersValidator]
|
||||
]
|
||||
widget: django.forms.widgets.TextInput
|
||||
max_length: Optional[Union[int, str]] = ...
|
||||
min_length: Optional[Union[int, str]] = ...
|
||||
@@ -292,7 +294,9 @@ class FileField(Field):
|
||||
def to_python(self, data: Optional[Union[SimpleUploadedFile, str]]) -> Optional[SimpleUploadedFile]: ...
|
||||
def clean(self, data: Any, initial: Optional[Union[FieldFile, str]] = ...) -> Optional[Union[bool, File, str]]: ...
|
||||
def bound_data(self, data: Any, initial: Optional[FieldFile]) -> Optional[Union[File, str]]: ...
|
||||
def has_changed(self, initial: Optional[Union[FieldFile, str]], data: Optional[Union[Dict[str, str], str]]) -> bool: ...
|
||||
def has_changed(
|
||||
self, initial: Optional[Union[FieldFile, str]], data: Optional[Union[Dict[str, str], str]]
|
||||
) -> bool: ...
|
||||
|
||||
class ImageField(FileField):
|
||||
allow_empty_file: bool
|
||||
@@ -423,7 +427,9 @@ class MultipleChoiceField(ChoiceField):
|
||||
default_error_messages: Any = ...
|
||||
def to_python(self, value: Optional[Union[List[Union[int, str]], Tuple, str]]) -> List[str]: ...
|
||||
def validate(self, value: List[str]) -> None: ...
|
||||
def has_changed(self, initial: Optional[Union[List[int], List[str], str]], data: Optional[Union[List[str], str]]) -> bool: ...
|
||||
def has_changed(
|
||||
self, initial: Optional[Union[List[int], List[str], str]], data: Optional[Union[List[str], str]]
|
||||
) -> bool: ...
|
||||
|
||||
class TypedMultipleChoiceField(MultipleChoiceField):
|
||||
disabled: bool
|
||||
@@ -466,7 +472,9 @@ class MultiValueField(Field):
|
||||
require_all_fields: bool = ...
|
||||
fields: Any = ...
|
||||
def __init__(self, fields: Tuple[Field, Field], *, require_all_fields: bool = ..., **kwargs: Any) -> None: ...
|
||||
def __deepcopy__(self, memo: Dict[int, Union[List[Tuple[str, str]], OrderedDict, Field, Widget]]) -> MultiValueField: ...
|
||||
def __deepcopy__(
|
||||
self, memo: Dict[int, Union[List[Tuple[str, str]], OrderedDict, Field, Widget]]
|
||||
) -> MultiValueField: ...
|
||||
def validate(self, value: Union[datetime, str]) -> None: ...
|
||||
def clean(
|
||||
self, value: Optional[Union[List[None], List[datetime], List[str], datetime, str]]
|
||||
|
||||
@@ -295,7 +295,9 @@ class ModelMultipleChoiceField(ModelChoiceField):
|
||||
default_error_messages: Any = ...
|
||||
def __init__(self, queryset: QuerySet, **kwargs: Any) -> None: ...
|
||||
def to_python(self, value: Union[List[str], Tuple[int, ...]]) -> List[Model]: ...
|
||||
def clean(self, value: Optional[Union[List[Dict[str, str]], List[List[str]], List[Model], Tuple, str]]) -> QuerySet: ...
|
||||
def clean(
|
||||
self, value: Optional[Union[List[Dict[str, str]], List[List[str]], List[Model], Tuple, str]]
|
||||
) -> QuerySet: ...
|
||||
def prepare_value(self, value: Any) -> Optional[Union[List[Dict[str, str]], List[List[str]], int, str]]: ...
|
||||
def has_changed(
|
||||
self, initial: Optional[Union[List[Model], QuerySet, str]], data: Optional[Union[List[int], List[str], str]]
|
||||
|
||||
@@ -18,7 +18,10 @@ class BaseRenderer:
|
||||
str,
|
||||
Union[
|
||||
Dict[
|
||||
str, Optional[Union[Dict[str, bool], List[Dict[str, Optional[Union[Dict[str, str], bool, str]]]], bool, str]]
|
||||
str,
|
||||
Optional[
|
||||
Union[Dict[str, bool], List[Dict[str, Optional[Union[Dict[str, str], bool, str]]]], bool, str]
|
||||
],
|
||||
],
|
||||
Dict[
|
||||
str,
|
||||
@@ -45,13 +48,19 @@ class BaseRenderer:
|
||||
str,
|
||||
Union[
|
||||
Dict[str, Union[int, str]],
|
||||
List[Tuple[Optional[str], List[Dict[str, Union[Dict[str, Union[bool, str]], time, int, str]]], int]],
|
||||
List[
|
||||
Tuple[
|
||||
Optional[str], List[Dict[str, Union[Dict[str, Union[bool, str]], time, int, str]]], int
|
||||
]
|
||||
],
|
||||
List[str],
|
||||
int,
|
||||
str,
|
||||
],
|
||||
],
|
||||
Dict[str, Union[Dict[str, str], List[Dict[str, Union[Dict[str, str], bool, str]]], List[int], bool, str]],
|
||||
Dict[
|
||||
str, Union[Dict[str, str], List[Dict[str, Union[Dict[str, str], bool, str]]], List[int], bool, str]
|
||||
],
|
||||
],
|
||||
],
|
||||
request: None = ...,
|
||||
|
||||
@@ -19,7 +19,9 @@ class ErrorList(UserList, list):
|
||||
data: List[Union[django.core.exceptions.ValidationError, str]]
|
||||
error_class: str = ...
|
||||
def __init__(
|
||||
self, initlist: Optional[Union[List[ValidationError], List[str], ErrorList]] = ..., error_class: Optional[str] = ...
|
||||
self,
|
||||
initlist: Optional[Union[List[ValidationError], List[str], ErrorList]] = ...,
|
||||
error_class: Optional[str] = ...,
|
||||
) -> None: ...
|
||||
def as_data(self) -> List[ValidationError]: ...
|
||||
def get_json_data(self, escape_html: bool = ...) -> List[Dict[str, str]]: ...
|
||||
|
||||
@@ -67,16 +67,24 @@ class Widget:
|
||||
],
|
||||
]: ...
|
||||
def render(
|
||||
self, name: str, value: Any, attrs: Optional[Dict[str, Union[bool, str]]] = ..., renderer: Optional[EngineMixin] = ...
|
||||
self,
|
||||
name: str,
|
||||
value: Any,
|
||||
attrs: Optional[Dict[str, Union[bool, str]]] = ...,
|
||||
renderer: Optional[EngineMixin] = ...,
|
||||
) -> SafeText: ...
|
||||
def build_attrs(
|
||||
self, base_attrs: Dict[str, Union[float, str]], extra_attrs: Optional[Dict[str, Union[bool, str]]] = ...
|
||||
) -> Dict[str, Union[Decimal, float, str]]: ...
|
||||
def value_from_datadict(self, data: dict, files: Union[Dict[str, SimpleUploadedFile], MultiValueDict], name: str) -> Any: ...
|
||||
def value_from_datadict(
|
||||
self, data: dict, files: Union[Dict[str, SimpleUploadedFile], MultiValueDict], name: str
|
||||
) -> Any: ...
|
||||
def value_omitted_from_data(
|
||||
self,
|
||||
data: Union[
|
||||
Dict[str, Optional[Union[List[int], date, int, str]]], Dict[str, Union[datetime, Decimal, int, str]], QueryDict
|
||||
Dict[str, Optional[Union[List[int], date, int, str]]],
|
||||
Dict[str, Union[datetime, Decimal, int, str]],
|
||||
QueryDict,
|
||||
],
|
||||
files: Union[Dict[str, SimpleUploadedFile], MultiValueDict],
|
||||
name: str,
|
||||
@@ -163,7 +171,10 @@ class MultipleHiddenInput(HiddenInput):
|
||||
],
|
||||
]: ...
|
||||
def value_from_datadict(
|
||||
self, data: Union[Dict[str, List[str]], Dict[str, Tuple[int, ...]], MultiValueDict], files: Dict[Any, Any], name: str
|
||||
self,
|
||||
data: Union[Dict[str, List[str]], Dict[str, Tuple[int, ...]], MultiValueDict],
|
||||
files: Dict[Any, Any],
|
||||
name: str,
|
||||
) -> Union[List[str], Tuple[int, ...]]: ...
|
||||
def format_value(self, value: Optional[Union[List[int], List[str]]]) -> Union[List[int], List[str]]: ...
|
||||
|
||||
@@ -283,7 +294,9 @@ class ChoiceWidget(Widget):
|
||||
def __init__(
|
||||
self,
|
||||
attrs: Optional[Dict[str, Union[bool, str]]] = ...,
|
||||
choices: Union[Iterator[Any], List[List[Union[int, str]]], List[Tuple[Union[time, int], int]], List[int], Tuple] = ...,
|
||||
choices: Union[
|
||||
Iterator[Any], List[List[Union[int, str]]], List[Tuple[Union[time, int], int]], List[int], Tuple
|
||||
] = ...,
|
||||
) -> None: ...
|
||||
def __deepcopy__(self, memo: Dict[int, List[Any]]) -> ChoiceWidget: ...
|
||||
def subwidgets(self, name: str, value: Optional[List[str]], attrs: Dict[str, Union[bool, str]] = ...) -> None: ...
|
||||
@@ -316,7 +329,8 @@ class ChoiceWidget(Widget):
|
||||
Tuple[
|
||||
Optional[str],
|
||||
Union[
|
||||
List[Dict[str, Union[Dict[str, bool], bool, str]]], List[Dict[str, Union[Dict[str, str], bool, str]]]
|
||||
List[Dict[str, Union[Dict[str, bool], bool, str]]],
|
||||
List[Dict[str, Union[Dict[str, str], bool, str]]],
|
||||
],
|
||||
int,
|
||||
]
|
||||
@@ -349,7 +363,10 @@ class Select(ChoiceWidget):
|
||||
checked_attribute: Any = ...
|
||||
option_inherits_attrs: bool = ...
|
||||
def get_context(
|
||||
self, name: str, value: Optional[Union[List[int], List[str], int, str]], attrs: Optional[Dict[str, Union[bool, str]]]
|
||||
self,
|
||||
name: str,
|
||||
value: Optional[Union[List[int], List[str], int, str]],
|
||||
attrs: Optional[Dict[str, Union[bool, str]]],
|
||||
) -> Dict[
|
||||
str,
|
||||
Dict[
|
||||
@@ -370,12 +387,17 @@ class NullBooleanSelect(Select):
|
||||
def __init__(self, attrs: None = ...) -> None: ...
|
||||
def format_value(self, value: Optional[Union[bool, str]]) -> str: ...
|
||||
def value_from_datadict(
|
||||
self, data: Union[Dict[str, Union[bool, str]], QueryDict], files: Union[Dict[Any, Any], MultiValueDict], name: str
|
||||
self,
|
||||
data: Union[Dict[str, Union[bool, str]], QueryDict],
|
||||
files: Union[Dict[Any, Any], MultiValueDict],
|
||||
name: str,
|
||||
) -> Optional[bool]: ...
|
||||
|
||||
class SelectMultiple(Select):
|
||||
attrs: Dict[Any, Any]
|
||||
choices: Union[List[Tuple[str, Union[Tuple[Tuple[str, str], Tuple[str, str]], str]]], django.forms.models.ModelChoiceIterator]
|
||||
choices: Union[
|
||||
List[Tuple[str, Union[Tuple[Tuple[str, str], Tuple[str, str]], str]]], django.forms.models.ModelChoiceIterator
|
||||
]
|
||||
is_required: bool
|
||||
allow_multiple_selected: bool = ...
|
||||
def value_from_datadict(
|
||||
@@ -401,7 +423,8 @@ class RadioSelect(ChoiceWidget):
|
||||
class CheckboxSelectMultiple(ChoiceWidget):
|
||||
attrs: Dict[str, str]
|
||||
choices: Union[
|
||||
List[Tuple[datetime.time, Union[Tuple[Tuple[str, str], Tuple[str, str]], str]]], django.forms.models.ModelChoiceIterator
|
||||
List[Tuple[datetime.time, Union[Tuple[Tuple[str, str], Tuple[str, str]], str]]],
|
||||
django.forms.models.ModelChoiceIterator,
|
||||
]
|
||||
is_required: bool
|
||||
allow_multiple_selected: bool = ...
|
||||
@@ -424,7 +447,10 @@ class MultiWidget(Widget):
|
||||
@property
|
||||
def is_hidden(self) -> bool: ...
|
||||
def get_context(
|
||||
self, name: str, value: Optional[Union[List[datetime], datetime, str]], attrs: Optional[Dict[str, Union[bool, str]]]
|
||||
self,
|
||||
name: str,
|
||||
value: Optional[Union[List[datetime], datetime, str]],
|
||||
attrs: Optional[Dict[str, Union[bool, str]]],
|
||||
) -> Dict[
|
||||
str,
|
||||
Union[
|
||||
@@ -463,7 +489,10 @@ class MultiWidget(Widget):
|
||||
]: ...
|
||||
def id_for_label(self, id_: str) -> str: ...
|
||||
def value_from_datadict(
|
||||
self, data: Union[Dict[str, Union[List[str], str]], QueryDict], files: Union[Dict[Any, Any], MultiValueDict], name: str
|
||||
self,
|
||||
data: Union[Dict[str, Union[List[str], str]], QueryDict],
|
||||
files: Union[Dict[Any, Any], MultiValueDict],
|
||||
name: str,
|
||||
) -> Union[List[None], List[str]]: ...
|
||||
def value_omitted_from_data(
|
||||
self, data: Union[Dict[str, str], QueryDict], files: Union[Dict[Any, Any], MultiValueDict], name: str
|
||||
|
||||
@@ -33,7 +33,9 @@ class HttpRequest:
|
||||
def get_port(self) -> str: ...
|
||||
def get_full_path(self, force_append_slash: bool = ...) -> str: ...
|
||||
def get_full_path_info(self, force_append_slash: bool = ...) -> str: ...
|
||||
def get_signed_cookie(self, key: str, default: Any = ..., salt: str = ..., max_age: Optional[int] = ...) -> Optional[str]: ...
|
||||
def get_signed_cookie(
|
||||
self, key: str, default: Any = ..., salt: str = ..., max_age: Optional[int] = ...
|
||||
) -> Optional[str]: ...
|
||||
def get_raw_uri(self) -> str: ...
|
||||
def build_absolute_uri(self, location: Optional[str] = ...) -> str: ...
|
||||
@property
|
||||
|
||||
@@ -23,7 +23,11 @@ class HttpResponseBase:
|
||||
cookies: cookies.SimpleCookie = ...
|
||||
closed: bool = ...
|
||||
def __init__(
|
||||
self, content_type: Optional[str] = ..., status: Any = ..., reason: Optional[str] = ..., charset: Optional[str] = ...
|
||||
self,
|
||||
content_type: Optional[str] = ...,
|
||||
status: Any = ...,
|
||||
reason: Optional[str] = ...,
|
||||
charset: Optional[str] = ...,
|
||||
) -> None: ...
|
||||
@property
|
||||
def reason_phrase(self): ...
|
||||
|
||||
@@ -12,7 +12,9 @@ class UpdateCacheMiddleware(MiddlewareMixin):
|
||||
cache: BaseCache = ...
|
||||
get_response: Optional[Callable] = ...
|
||||
def __init__(self, get_response: Optional[Callable] = ...) -> None: ...
|
||||
def process_response(self, request: HttpRequest, response: Union[HttpResponseBase, str]) -> Union[HttpResponseBase, str]: ...
|
||||
def process_response(
|
||||
self, request: HttpRequest, response: Union[HttpResponseBase, str]
|
||||
) -> Union[HttpResponseBase, str]: ...
|
||||
|
||||
class FetchFromCacheMiddleware(MiddlewareMixin):
|
||||
key_prefix: str = ...
|
||||
|
||||
@@ -37,7 +37,11 @@ class Template:
|
||||
str,
|
||||
Dict[
|
||||
str,
|
||||
Optional[Union[Dict[str, str], List[Dict[str, Optional[Union[Dict[str, str], bool, str]]]], bool, str]],
|
||||
Optional[
|
||||
Union[
|
||||
Dict[str, str], List[Dict[str, Optional[Union[Dict[str, str], bool, str]]]], bool, str
|
||||
]
|
||||
],
|
||||
],
|
||||
],
|
||||
Dict[
|
||||
@@ -83,7 +87,13 @@ class Template:
|
||||
str,
|
||||
Union[
|
||||
Dict[str, str],
|
||||
List[Tuple[Optional[str], List[Dict[str, Union[Dict[str, Union[bool, str]], time, int, str]]], int]],
|
||||
List[
|
||||
Tuple[
|
||||
Optional[str],
|
||||
List[Dict[str, Union[Dict[str, Union[bool, str]], time, int, str]]],
|
||||
int,
|
||||
]
|
||||
],
|
||||
List[str],
|
||||
bool,
|
||||
str,
|
||||
|
||||
@@ -42,7 +42,10 @@ class Origin:
|
||||
template_name: Optional[Union[bytes, str]] = ...
|
||||
loader: Optional[Union[django.template.backends.dummy.TemplateStrings, django.template.loaders.base.Loader]] = ...
|
||||
def __init__(
|
||||
self, name: str, template_name: Optional[Union[bytes, str]] = ..., loader: Optional[Union[TemplateStrings, Loader]] = ...
|
||||
self,
|
||||
name: str,
|
||||
template_name: Optional[Union[bytes, str]] = ...,
|
||||
loader: Optional[Union[TemplateStrings, Loader]] = ...,
|
||||
) -> None: ...
|
||||
def __eq__(self, other: Origin) -> bool: ...
|
||||
@property
|
||||
@@ -55,7 +58,11 @@ class Template:
|
||||
source: str = ...
|
||||
nodelist: django.template.base.NodeList = ...
|
||||
def __init__(
|
||||
self, template_string: str, origin: Optional[Origin] = ..., name: Optional[str] = ..., engine: Optional[Engine] = ...
|
||||
self,
|
||||
template_string: str,
|
||||
origin: Optional[Origin] = ...,
|
||||
name: Optional[str] = ...,
|
||||
engine: Optional[Engine] = ...,
|
||||
) -> None: ...
|
||||
def __iter__(self) -> None: ...
|
||||
def render(self, context: Context) -> Any: ...
|
||||
@@ -72,7 +79,11 @@ class Token:
|
||||
lineno: Optional[int] = ...
|
||||
position: Optional[Tuple[int, int]] = ...
|
||||
def __init__(
|
||||
self, token_type: TokenType, contents: str, position: Optional[Tuple[int, int]] = ..., lineno: Optional[int] = ...
|
||||
self,
|
||||
token_type: TokenType,
|
||||
contents: str,
|
||||
position: Optional[Tuple[int, int]] = ...,
|
||||
lineno: Optional[int] = ...,
|
||||
) -> None: ...
|
||||
def split_contents(self) -> List[str]: ...
|
||||
|
||||
@@ -81,7 +92,9 @@ class Lexer:
|
||||
verbatim: Union[bool, str] = ...
|
||||
def __init__(self, template_string: str) -> None: ...
|
||||
def tokenize(self) -> List[Token]: ...
|
||||
def create_token(self, token_string: str, position: Optional[Tuple[int, int]], lineno: int, in_tag: bool) -> Token: ...
|
||||
def create_token(
|
||||
self, token_string: str, position: Optional[Tuple[int, int]], lineno: int, in_tag: bool
|
||||
) -> Token: ...
|
||||
|
||||
class DebugLexer(Lexer):
|
||||
template_string: str
|
||||
|
||||
@@ -57,7 +57,9 @@ class Context(BaseContext):
|
||||
template_name: Optional[str] = ...
|
||||
render_context: django.template.context.RenderContext = ...
|
||||
template: Optional[django.template.base.Template] = ...
|
||||
def __init__(self, dict_: Any = ..., autoescape: bool = ..., use_l10n: Optional[bool] = ..., use_tz: None = ...) -> None: ...
|
||||
def __init__(
|
||||
self, dict_: Any = ..., autoescape: bool = ..., use_l10n: Optional[bool] = ..., use_tz: None = ...
|
||||
) -> None: ...
|
||||
def bind_template(self, template: Template) -> Iterator[None]: ...
|
||||
def __copy__(self) -> Context: ...
|
||||
def update(self, other_dict: Union[Dict[str, Model], Dict[str, int], Dict[str, str], Context]) -> ContextDict: ...
|
||||
@@ -96,7 +98,12 @@ class RequestContext(Context):
|
||||
Union[
|
||||
Dict[str, Union[Dict[str, str], List[Dict[str, str]], bool]],
|
||||
Dict[str, Union[List[Any], ChangeList, int, str]],
|
||||
Dict[str, Union[List[Dict[str, Optional[Union[int, str]]]], List[ResultList], List[BoundField], ChangeList, int]],
|
||||
Dict[
|
||||
str,
|
||||
Union[
|
||||
List[Dict[str, Optional[Union[int, str]]]], List[ResultList], List[BoundField], ChangeList, int
|
||||
],
|
||||
],
|
||||
Dict[str, Union[ChangeList, int, range, str]],
|
||||
Context,
|
||||
]
|
||||
|
||||
@@ -72,7 +72,8 @@ def unordered_list(
|
||||
value: Union[Iterator[Any], List[Union[List[Union[List[Union[List[str], str]], str]], str]]], autoescape: bool = ...
|
||||
) -> SafeText: ...
|
||||
def add(
|
||||
value: Union[List[int], Tuple[int, int], date, int, str], arg: Union[List[int], Tuple[int, int], timedelta, int, str]
|
||||
value: Union[List[int], Tuple[int, int], date, int, str],
|
||||
arg: Union[List[int], Tuple[int, int], timedelta, int, str],
|
||||
) -> Union[List[int], Tuple[int, int, int, int], date, int, str]: ...
|
||||
def get_digit(value: Union[int, str], arg: int) -> Union[int, str]: ...
|
||||
def date(value: Optional[Union[datetime, str]], arg: Optional[str] = ...) -> str: ...
|
||||
|
||||
@@ -57,7 +57,9 @@ class CycleNode(Node):
|
||||
cyclevars: List[django.template.base.FilterExpression] = ...
|
||||
variable_name: Optional[str] = ...
|
||||
silent: bool = ...
|
||||
def __init__(self, cyclevars: List[FilterExpression], variable_name: Optional[str] = ..., silent: bool = ...) -> None: ...
|
||||
def __init__(
|
||||
self, cyclevars: List[FilterExpression], variable_name: Optional[str] = ..., silent: bool = ...
|
||||
) -> None: ...
|
||||
def render(self, context: Context) -> str: ...
|
||||
def reset(self, context: Context) -> None: ...
|
||||
|
||||
@@ -132,7 +134,9 @@ class IfEqualNode(Node):
|
||||
class IfNode(Node):
|
||||
origin: django.template.base.Origin
|
||||
token: django.template.base.Token
|
||||
conditions_nodelists: List[Tuple[Optional[django.template.defaulttags.TemplateLiteral], django.template.base.NodeList]] = ...
|
||||
conditions_nodelists: List[
|
||||
Tuple[Optional[django.template.defaulttags.TemplateLiteral], django.template.base.NodeList]
|
||||
] = ...
|
||||
def __init__(self, conditions_nodelists: List[Tuple[Optional[TemplateLiteral], NodeList]]) -> None: ...
|
||||
def __iter__(self) -> None: ...
|
||||
@property
|
||||
@@ -203,7 +207,11 @@ class URLNode(Node):
|
||||
kwargs: Dict[str, django.template.base.FilterExpression] = ...
|
||||
asvar: Optional[str] = ...
|
||||
def __init__(
|
||||
self, view_name: FilterExpression, args: List[FilterExpression], kwargs: Dict[str, FilterExpression], asvar: Optional[str]
|
||||
self,
|
||||
view_name: FilterExpression,
|
||||
args: List[FilterExpression],
|
||||
kwargs: Dict[str, FilterExpression],
|
||||
asvar: Optional[str],
|
||||
) -> None: ...
|
||||
def render(self, context: Context) -> str: ...
|
||||
|
||||
@@ -222,7 +230,11 @@ class WidthRatioNode(Node):
|
||||
max_width: django.template.base.FilterExpression = ...
|
||||
asvar: Optional[str] = ...
|
||||
def __init__(
|
||||
self, val_expr: FilterExpression, max_expr: FilterExpression, max_width: FilterExpression, asvar: Optional[str] = ...
|
||||
self,
|
||||
val_expr: FilterExpression,
|
||||
max_expr: FilterExpression,
|
||||
max_width: FilterExpression,
|
||||
asvar: Optional[str] = ...,
|
||||
) -> None: ...
|
||||
def render(self, context: Context) -> str: ...
|
||||
|
||||
|
||||
@@ -48,8 +48,12 @@ class Engine:
|
||||
def get_template_loaders(
|
||||
self, template_loaders: Union[List[List[Union[Dict[str, str], str]]], List[Tuple[str, List[str]]], List[str]]
|
||||
) -> List[Loader]: ...
|
||||
def find_template_loader(self, loader: Union[List[Union[Dict[str, str], str]], Tuple[str, List[str]], str]) -> Loader: ...
|
||||
def find_template(self, name: str, dirs: None = ..., skip: Optional[List[Origin]] = ...) -> Tuple[Template, Origin]: ...
|
||||
def find_template_loader(
|
||||
self, loader: Union[List[Union[Dict[str, str], str]], Tuple[str, List[str]], str]
|
||||
) -> Loader: ...
|
||||
def find_template(
|
||||
self, name: str, dirs: None = ..., skip: Optional[List[Origin]] = ...
|
||||
) -> Tuple[Template, Origin]: ...
|
||||
def from_string(self, template_code: str) -> Template: ...
|
||||
def get_template(self, template_name: str) -> Template: ...
|
||||
def render_to_string(self, template_name: str, context: Any = ...) -> SafeText: ...
|
||||
|
||||
@@ -18,14 +18,21 @@ class Library:
|
||||
) -> Callable: ...
|
||||
def tag_function(self, func: Callable) -> Callable: ...
|
||||
def filter(
|
||||
self, name: Optional[Union[Callable, str]] = ..., filter_func: Optional[Union[Callable, str]] = ..., **flags: Any
|
||||
self,
|
||||
name: Optional[Union[Callable, str]] = ...,
|
||||
filter_func: Optional[Union[Callable, str]] = ...,
|
||||
**flags: Any
|
||||
) -> Callable: ...
|
||||
def filter_function(self, func: Callable, **flags: Any) -> Callable: ...
|
||||
def simple_tag(
|
||||
self, func: Optional[Union[Callable, str]] = ..., takes_context: Optional[bool] = ..., name: Optional[str] = ...
|
||||
) -> Callable: ...
|
||||
def inclusion_tag(
|
||||
self, filename: Union[Template, str], func: None = ..., takes_context: Optional[bool] = ..., name: Optional[str] = ...
|
||||
self,
|
||||
filename: Union[Template, str],
|
||||
func: None = ...,
|
||||
takes_context: Optional[bool] = ...,
|
||||
name: Optional[str] = ...,
|
||||
) -> Callable: ...
|
||||
|
||||
class TagHelperNode(Node):
|
||||
@@ -34,7 +41,11 @@ class TagHelperNode(Node):
|
||||
args: Any = ...
|
||||
kwargs: Any = ...
|
||||
def __init__(
|
||||
self, func: Callable, takes_context: Optional[bool], args: List[FilterExpression], kwargs: Dict[str, FilterExpression]
|
||||
self,
|
||||
func: Callable,
|
||||
takes_context: Optional[bool],
|
||||
args: List[FilterExpression],
|
||||
kwargs: Dict[str, FilterExpression],
|
||||
) -> None: ...
|
||||
def get_resolved_arguments(self, context: Context) -> Tuple[List[int], Dict[str, Union[SafeText, int]]]: ...
|
||||
|
||||
|
||||
@@ -5,7 +5,9 @@ from django.template.backends.django import Template as DjangoTemplate
|
||||
from django.template.backends.dummy import Template as DummyTemplate
|
||||
from django.template.backends.jinja2 import Template as Jinja2Template
|
||||
|
||||
def get_template(template_name: str, using: Optional[str] = ...) -> Union[DjangoTemplate, DummyTemplate, Jinja2Template]: ...
|
||||
def get_template(
|
||||
template_name: str, using: Optional[str] = ...
|
||||
) -> Union[DjangoTemplate, DummyTemplate, Jinja2Template]: ...
|
||||
def select_template(
|
||||
template_name_list: Union[List[str], str], using: Optional[str] = ...
|
||||
) -> Union[DjangoTemplate, DummyTemplate, Jinja2Template]: ...
|
||||
|
||||
@@ -36,7 +36,9 @@ class IfParser:
|
||||
current_token: Any = ...
|
||||
def __init__(
|
||||
self,
|
||||
tokens: Union[List[Optional[Union[List[int], str]]], List[Optional[Union[int, str]]], List[Union[List[int], int, str]]],
|
||||
tokens: Union[
|
||||
List[Optional[Union[List[int], str]]], List[Optional[Union[int, str]]], List[Union[List[int], int, str]]
|
||||
],
|
||||
) -> None: ...
|
||||
def translate_token(self, token: Optional[Union[List[int], int, str]]) -> Literal: ...
|
||||
def next_token(self) -> Literal: ...
|
||||
|
||||
@@ -13,7 +13,9 @@ class datetimeobject(datetime): ...
|
||||
|
||||
def localtime(value: Optional[Union[datetime, str]]) -> Union[datetimeobject, str]: ...
|
||||
def utc(value: Optional[Union[datetime, str]]) -> Union[datetimeobject, str]: ...
|
||||
def do_timezone(value: Optional[Union[datetime, str]], arg: Optional[Union[FixedOffset, str]]) -> Union[datetimeobject, str]: ...
|
||||
def do_timezone(
|
||||
value: Optional[Union[datetime, str]], arg: Optional[Union[FixedOffset, str]]
|
||||
) -> Union[datetimeobject, str]: ...
|
||||
|
||||
class LocalTimeNode(Node):
|
||||
origin: django.template.base.Origin
|
||||
|
||||
@@ -1,3 +1,7 @@
|
||||
from .testcases import TestCase as TestCase, TransactionTestCase as TransactionTestCase, SimpleTestCase as SimpleTestCase
|
||||
from .testcases import (
|
||||
TestCase as TestCase,
|
||||
TransactionTestCase as TransactionTestCase,
|
||||
SimpleTestCase as SimpleTestCase,
|
||||
)
|
||||
|
||||
from .utils import override_settings as override_settings
|
||||
|
||||
@@ -50,7 +50,12 @@ class RequestFactory:
|
||||
) -> Union[WSGIRequest, HttpResponse]: ...
|
||||
def trace(self, path: str, secure: bool = ..., **extra: Any) -> Union[WSGIRequest, HttpResponse]: ...
|
||||
def options(
|
||||
self, path: str, data: Union[Dict[str, str], str] = ..., content_type: str = ..., secure: bool = ..., **extra: Any
|
||||
self,
|
||||
path: str,
|
||||
data: Union[Dict[str, str], str] = ...,
|
||||
content_type: str = ...,
|
||||
secure: bool = ...,
|
||||
**extra: Any
|
||||
) -> Union[WSGIRequest, HttpResponse]: ...
|
||||
def put(
|
||||
self,
|
||||
@@ -109,7 +114,12 @@ class Client(RequestFactory):
|
||||
self, path: str, data: Any = ..., content_type: str = ..., follow: bool = ..., secure: bool = ..., **extra: Any
|
||||
) -> HttpResponseBase: ...
|
||||
def head(
|
||||
self, path: str, data: Optional[Union[Dict[str, str], str]] = ..., follow: bool = ..., secure: bool = ..., **extra: Any
|
||||
self,
|
||||
path: str,
|
||||
data: Optional[Union[Dict[str, str], str]] = ...,
|
||||
follow: bool = ...,
|
||||
secure: bool = ...,
|
||||
**extra: Any
|
||||
) -> HttpResponse: ...
|
||||
def options(
|
||||
self,
|
||||
|
||||
@@ -115,7 +115,10 @@ class DiscoverRunner:
|
||||
def add_arguments(cls, parser: ArgumentParser) -> None: ...
|
||||
def setup_test_environment(self, **kwargs: Any) -> None: ...
|
||||
def build_suite(
|
||||
self, test_labels: Union[List[str], Tuple[str, str]] = ..., extra_tests: Optional[List[Any]] = ..., **kwargs: Any
|
||||
self,
|
||||
test_labels: Union[List[str], Tuple[str, str]] = ...,
|
||||
extra_tests: Optional[List[Any]] = ...,
|
||||
**kwargs: Any
|
||||
) -> TestSuite: ...
|
||||
def setup_databases(self, **kwargs: Any) -> List[Tuple[BaseDatabaseWrapper, str, bool]]: ...
|
||||
def get_resultclass(self) -> Optional[Type[DebugSQLTextTestResult]]: ...
|
||||
@@ -128,7 +131,9 @@ class DiscoverRunner:
|
||||
def run_tests(self, test_labels: List[str], extra_tests: List[Any] = ..., **kwargs: Any) -> int: ...
|
||||
|
||||
def is_discoverable(label: str) -> bool: ...
|
||||
def reorder_suite(suite: TestSuite, classes: Tuple[Type[TestCase], Type[SimpleTestCase]], reverse: bool = ...) -> TestSuite: ...
|
||||
def reorder_suite(
|
||||
suite: TestSuite, classes: Tuple[Type[TestCase], Type[SimpleTestCase]], reverse: bool = ...
|
||||
) -> TestSuite: ...
|
||||
def partition_suite_by_type(
|
||||
suite: TestSuite, classes: Tuple[Type[TestCase], Type[SimpleTestCase]], bins: List[OrderedSet], reverse: bool = ...
|
||||
) -> None: ...
|
||||
|
||||
@@ -84,10 +84,20 @@ class SimpleTestCase(unittest.TestCase):
|
||||
html: bool = ...,
|
||||
) -> None: ...
|
||||
def assertNotContains(
|
||||
self, response: HttpResponse, text: Union[bytes, str], status_code: int = ..., msg_prefix: str = ..., html: bool = ...
|
||||
self,
|
||||
response: HttpResponse,
|
||||
text: Union[bytes, str],
|
||||
status_code: int = ...,
|
||||
msg_prefix: str = ...,
|
||||
html: bool = ...,
|
||||
) -> None: ...
|
||||
def assertFormError(
|
||||
self, response: HttpResponse, form: str, field: Optional[str], errors: Union[List[str], str], msg_prefix: str = ...
|
||||
self,
|
||||
response: HttpResponse,
|
||||
form: str,
|
||||
field: Optional[str],
|
||||
errors: Union[List[str], str],
|
||||
msg_prefix: str = ...,
|
||||
) -> None: ...
|
||||
def assertFormsetError(
|
||||
self,
|
||||
@@ -125,7 +135,9 @@ class SimpleTestCase(unittest.TestCase):
|
||||
) -> Any: ...
|
||||
def assertHTMLEqual(self, html1: str, html2: str, msg: None = ...) -> None: ...
|
||||
def assertHTMLNotEqual(self, html1: str, html2: str, msg: None = ...) -> None: ...
|
||||
def assertInHTML(self, needle: str, haystack: SafeText, count: Optional[int] = ..., msg_prefix: str = ...) -> None: ...
|
||||
def assertInHTML(
|
||||
self, needle: str, haystack: SafeText, count: Optional[int] = ..., msg_prefix: str = ...
|
||||
) -> None: ...
|
||||
def assertJSONEqual(self, raw: str, expected_data: Union[Dict[str, str], bool, str], msg: None = ...) -> None: ...
|
||||
def assertJSONNotEqual(self, raw: str, expected_data: str, msg: None = ...) -> None: ...
|
||||
def assertXMLEqual(self, xml1: str, xml2: str, msg: None = ...) -> None: ...
|
||||
|
||||
@@ -87,7 +87,10 @@ class URLPattern:
|
||||
callback: Callable,
|
||||
default_args: Optional[
|
||||
Union[
|
||||
Dict[str, Dict[str, Type[FlatPageSitemap]]], Dict[str, Dict[str, Sitemap]], Dict[str, OrderedDict], Dict[str, str]
|
||||
Dict[str, Dict[str, Type[FlatPageSitemap]]],
|
||||
Dict[str, Dict[str, Sitemap]],
|
||||
Dict[str, OrderedDict],
|
||||
Dict[str, str],
|
||||
]
|
||||
] = ...,
|
||||
name: Optional[str] = ...,
|
||||
|
||||
@@ -11,7 +11,10 @@ def patch_cache_control(response: HttpResponseBase, **kwargs: Any) -> None: ...
|
||||
def get_max_age(response: HttpResponse) -> Optional[int]: ...
|
||||
def set_response_etag(response: HttpResponseBase) -> HttpResponseBase: ...
|
||||
def get_conditional_response(
|
||||
request: WSGIRequest, etag: Optional[str] = ..., last_modified: Optional[int] = ..., response: Optional[HttpResponse] = ...
|
||||
request: WSGIRequest,
|
||||
etag: Optional[str] = ...,
|
||||
last_modified: Optional[int] = ...,
|
||||
response: Optional[HttpResponse] = ...,
|
||||
) -> Optional[HttpResponse]: ...
|
||||
def patch_response_headers(response: HttpResponseBase, cache_timeout: float = ...) -> None: ...
|
||||
def add_never_cache_headers(response: HttpResponseBase) -> None: ...
|
||||
|
||||
@@ -7,5 +7,9 @@ def salted_hmac(key_salt: str, value: Union[bytes, str], secret: Optional[Union[
|
||||
def get_random_string(length: int = ..., allowed_chars: str = ...) -> str: ...
|
||||
def constant_time_compare(val1: Union[bytes, str], val2: Union[bytes, str]) -> bool: ...
|
||||
def pbkdf2(
|
||||
password: Union[bytes, str], salt: Union[bytes, str], iterations: int, dklen: int = ..., digest: Optional[Callable] = ...
|
||||
password: Union[bytes, str],
|
||||
salt: Union[bytes, str],
|
||||
iterations: int,
|
||||
dklen: int = ...,
|
||||
digest: Optional[Callable] = ...,
|
||||
) -> bytes: ...
|
||||
|
||||
@@ -17,7 +17,9 @@ class OrderedSet:
|
||||
def __init__(
|
||||
self,
|
||||
iterable: Optional[
|
||||
Union[List[Tuple[str, str]], List[datetime], List[Combinable], List[int], List[str], List[UUID], OrderedDict]
|
||||
Union[
|
||||
List[Tuple[str, str]], List[datetime], List[Combinable], List[int], List[str], List[UUID], OrderedDict
|
||||
]
|
||||
] = ...,
|
||||
) -> None: ...
|
||||
def add(self, item: Union[Type[Model], SerializeMixin, LoggingCaptureMixin, int, TestCase]) -> None: ...
|
||||
@@ -45,13 +47,17 @@ class MultiValueDict(dict):
|
||||
def __setitem__(self, key: str, value: Optional[Union[int, str]]) -> None: ...
|
||||
def __copy__(self) -> MultiValueDict: ...
|
||||
def __deepcopy__(self, memo: Any): ...
|
||||
def get(self, key: str, default: Optional[Union[int, str]] = ...) -> Optional[Union[InMemoryUploadedFile, int, str]]: ...
|
||||
def get(
|
||||
self, key: str, default: Optional[Union[int, str]] = ...
|
||||
) -> Optional[Union[InMemoryUploadedFile, int, str]]: ...
|
||||
def getlist(self, key: Optional[Union[Callable, str]], default: Any = ...) -> Any: ...
|
||||
def setlist(self, key: Union[Callable, str], list_: List[str]) -> None: ...
|
||||
def setdefault(self, key: str, default: str = ...) -> str: ...
|
||||
def setlistdefault(
|
||||
self, key: Union[Callable, str], default_list: None = ...
|
||||
) -> Union[List[Tuple[List[Tuple[str, List[str]]], str, Dict[str, str], Dict[Any, Any]]], List[UploadedFile], List[str]]: ...
|
||||
) -> Union[
|
||||
List[Tuple[List[Tuple[str, List[str]]], str, Dict[str, str], Dict[Any, Any]]], List[UploadedFile], List[str]
|
||||
]: ...
|
||||
def appendlist(
|
||||
self,
|
||||
key: Union[Callable, str],
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user