mirror of
https://github.com/davidhalter/django-stubs.git
synced 2026-05-17 22:09:45 +08:00
black reformat, some fixes
This commit is contained in:
@@ -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: ...
|
||||
|
||||
Reference in New Issue
Block a user