enable more folders

This commit is contained in:
Maxim Kurnikov
2019-01-30 16:12:19 +03:00
parent 628c1224d6
commit 1868100bd9
5 changed files with 21 additions and 8 deletions

View File

@@ -1,3 +1,3 @@
from .messages import Warning as Warning, Info as Info, Debug as Debug, Error as Error, Critical as Critical from .messages import Warning as Warning, Info as Info, Debug as Debug, Error as Error, Critical as Critical
from .registry import run_checks as run_checks from .registry import run_checks as run_checks, Tags as Tags, register as register

View File

@@ -14,6 +14,7 @@ _ErrorMessagesToOverride = Dict[str, Any]
class Field(RegisterLookupMixin): class Field(RegisterLookupMixin):
widget: Widget widget: Widget
help_text: str help_text: str
db_table: str
def __init__( def __init__(
self, self,
verbose_name: Optional[str] = ..., verbose_name: Optional[str] = ...,

View File

@@ -52,7 +52,6 @@ class ManyToManyField(RelatedField, Generic[_T]):
rel_class: Any = ... rel_class: Any = ...
description: Any = ... description: Any = ...
has_null_arg: Any = ... has_null_arg: Any = ...
db_table: Any = ...
swappable: Any = ... swappable: Any = ...
def __init__( def __init__(
self, self,
@@ -64,7 +63,7 @@ class ManyToManyField(RelatedField, Generic[_T]):
through: Optional[Union[str, Type[Model]]] = ..., through: Optional[Union[str, Type[Model]]] = ...,
through_fields: Optional[Tuple[str, str]] = ..., through_fields: Optional[Tuple[str, str]] = ...,
db_constraint: bool = ..., db_constraint: bool = ...,
db_table: None = ..., db_table: Optional[str] = ...,
swappable: bool = ..., swappable: bool = ...,
**kwargs: Any **kwargs: Any
) -> None: ... ) -> None: ...

View File

@@ -25,3 +25,5 @@ class CsrfViewMiddleware(MiddlewareMixin):
self, request: HttpRequest, callback: Callable, callback_args: Tuple, callback_kwargs: Dict[str, Any] self, request: HttpRequest, callback: Callable, callback_args: Tuple, callback_kwargs: Dict[str, Any]
) -> Optional[HttpResponseForbidden]: ... ) -> Optional[HttpResponseForbidden]: ...
def process_response(self, request: HttpRequest, response: HttpResponseBase) -> HttpResponseBase: ... def process_response(self, request: HttpRequest, response: HttpResponseBase) -> HttpResponseBase: ...
def _compare_salted_tokens(request_csrf_token: str, csrf_token: str) -> bool: ...

View File

@@ -40,12 +40,14 @@ IGNORED_ERROR_PATTERNS = [
'Incompatible types in assignment (expression has type "RelatedFieldWidgetWrapper", variable has type "AdminRadioSelect")', 'Incompatible types in assignment (expression has type "RelatedFieldWidgetWrapper", variable has type "AdminRadioSelect")',
'has incompatible type "MockRequest"; expected "WSGIRequest"', 'has incompatible type "MockRequest"; expected "WSGIRequest"',
'"NullTranslations" has no attribute "_catalog"', '"NullTranslations" has no attribute "_catalog"',
'Definition of "as_sql" in base class',
'expression has type "property"',
re.compile(r'"Callable\[\[(Any(, )?)+\], Any\]" has no attribute'), re.compile(r'"Callable\[\[(Any(, )?)+\], Any\]" has no attribute'),
re.compile(r'"HttpResponseBase" has no attribute "[A-Za-z_]+"'), re.compile(r'"HttpResponseBase" has no attribute "[A-Za-z_]+"'),
re.compile(r'Incompatible types in assignment \(expression has type "Tuple\[\]", ' re.compile(r'Incompatible types in assignment \(expression has type "Tuple\[\]", '
r'variable has type "Tuple\[[A-Za-z, ]+\]"'), r'variable has type "Tuple\[[A-Za-z, ]+\]"'),
re.compile(r'"validate" of "[A-Za-z]+" does not return a value'), re.compile(r'"validate" of "[A-Za-z]+" does not return a value'),
re.compile(r'Module has no attribute "[A-Za-z]+"'), re.compile(r'Module has no attribute "[A-Za-z_]+"'),
re.compile(r'"[A-Za-z\[\]]+" has no attribute "getvalue"'), re.compile(r'"[A-Za-z\[\]]+" has no attribute "getvalue"'),
# TODO: remove when reassignment will be possible (in 0.670? ) # TODO: remove when reassignment will be possible (in 0.670? )
re.compile(r'Incompatible types in assignment \(expression has type "(QuerySet|List){1}\[[A-Za-z, ]+\]", ' re.compile(r'Incompatible types in assignment \(expression has type "(QuerySet|List){1}\[[A-Za-z, ]+\]", '
@@ -62,25 +64,34 @@ TESTS_DIRS = [
'admin_custom_urls', 'admin_custom_urls',
'admin_default_site', 'admin_default_site',
'admin_docs', 'admin_docs',
# TODO: 'admin_filters', # # TODO: 'admin_filters',
'admin_inlines', 'admin_inlines',
'admin_ordering', 'admin_ordering',
'admin_registration', 'admin_registration',
'admin_scripts', 'admin_scripts',
# TODO: 'admin_utils', # # TODO: 'admin_utils',
# TODO: 'admin_views', # # TODO: 'admin_views',
'admin_widgets', 'admin_widgets',
'aggregation', 'aggregation',
'aggregation_regress', 'aggregation_regress',
'annotations', 'annotations',
'app_loading', 'app_loading',
'apps', 'apps',
# TODO: auth_tests # # TODO: auth_tests
'base', 'base',
'bash_completion', 'bash_completion',
'basic', 'basic',
'builtin_server', 'builtin_server',
'bulk_create', 'bulk_create',
# TODO: 'cache',
# TODO: 'check_framework',
'choices',
'conditional_processing',
# TODO: 'contenttypes_tests',
'context_processors',
'csrf_tests',
'custom_columns',
# TODO: 'custom_lookups',
] ]