mirror of
https://github.com/davidhalter/django-stubs.git
synced 2025-12-18 01:45:59 +08:00
split error suppression for tests typechecking, fix ci, bunch of fixes
This commit is contained in:
@@ -14,6 +14,9 @@ class SupportsLen(Protocol):
|
||||
class SupportsCount(Protocol):
|
||||
def count(self) -> int: ...
|
||||
|
||||
class SupportsOrdered(Protocol):
|
||||
ordered: bool = ...
|
||||
|
||||
class Paginator:
|
||||
object_list: QuerySet = ...
|
||||
per_page: int = ...
|
||||
@@ -21,7 +24,7 @@ class Paginator:
|
||||
allow_empty_first_page: bool = ...
|
||||
def __init__(
|
||||
self,
|
||||
object_list: Union[SupportsLen, SupportsCount],
|
||||
object_list: Union[SupportsLen, SupportsCount, SupportsOrdered],
|
||||
per_page: Union[int, str],
|
||||
orphans: int = ...,
|
||||
allow_empty_first_page: bool = ...,
|
||||
|
||||
6
django-stubs/core/signals.pyi
Normal file
6
django-stubs/core/signals.pyi
Normal file
@@ -0,0 +1,6 @@
|
||||
from django.dispatch import Signal
|
||||
|
||||
request_started: Signal = ...
|
||||
request_finished: Signal = ...
|
||||
got_request_exception: Signal = ...
|
||||
setting_changed: Signal = ...
|
||||
Reference in New Issue
Block a user