run black over stubs, add checking to travis

This commit is contained in:
Maxim Kurnikov
2018-12-03 18:52:44 +03:00
parent d5bc7d4ab2
commit cf6119bf9b
420 changed files with 2295 additions and 8384 deletions

View File

@@ -2,29 +2,19 @@ from typing import Any, Optional
from django.core.handlers.wsgi import WSGIRequest
from django.http.request import HttpRequest
from django.http.response import (HttpResponseBase, HttpResponseNotFound,
HttpResponsePermanentRedirect)
from django.http.response import HttpResponseBase, HttpResponseNotFound, HttpResponsePermanentRedirect
from django.utils.deprecation import MiddlewareMixin
class CommonMiddleware(MiddlewareMixin):
get_response: Optional[Callable]
response_redirect_class: Any = ...
def process_request(
self, request: WSGIRequest
) -> Optional[HttpResponsePermanentRedirect]: ...
def process_request(self, request: WSGIRequest) -> Optional[HttpResponsePermanentRedirect]: ...
def should_redirect_with_slash(self, request: WSGIRequest) -> bool: ...
def get_full_path_with_slash(self, request: WSGIRequest) -> str: ...
def process_response(
self, request: HttpRequest, response: HttpResponseBase
) -> HttpResponseBase: ...
def process_response(self, request: HttpRequest, response: HttpResponseBase) -> HttpResponseBase: ...
class BrokenLinkEmailsMiddleware(MiddlewareMixin):
get_response: None
def process_response(
self, request: WSGIRequest, response: HttpResponseNotFound
) -> HttpResponseNotFound: ...
def process_response(self, request: WSGIRequest, response: HttpResponseNotFound) -> HttpResponseNotFound: ...
def is_internal_request(self, domain: str, referer: str) -> bool: ...
def is_ignorable_request(
self, request: WSGIRequest, uri: str, domain: str, referer: str
) -> bool: ...
def is_ignorable_request(self, request: WSGIRequest, uri: str, domain: str, referer: str) -> bool: ...