mirror of
https://github.com/davidhalter/django-stubs.git
synced 2025-12-30 08:04:25 +08:00
fixes, add some testing folders
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
from contextlib import ContextDecorator
|
||||
from typing import Any, Callable, Optional, Union, ContextManager
|
||||
from typing import Any, Callable, Optional, Union, Iterator, overload, ContextManager
|
||||
|
||||
from django.db import ProgrammingError
|
||||
|
||||
@@ -25,5 +25,12 @@ class Atomic(ContextDecorator):
|
||||
def __enter__(self) -> None: ...
|
||||
def __exit__(self, exc_type: None, exc_value: None, traceback: None) -> None: ...
|
||||
|
||||
def atomic(using: Optional[Union[Callable, str]] = ..., savepoint: bool = ...) -> ContextManager[Atomic]: ...
|
||||
@overload
|
||||
def atomic() -> Atomic: ...
|
||||
@overload
|
||||
def atomic(using: Optional[str] = ...,) -> ContextManager[Atomic]: ...
|
||||
@overload
|
||||
def atomic(using: Callable = ...) -> Callable: ...
|
||||
@overload
|
||||
def atomic(using: Optional[str] = ..., savepoint: bool = ...) -> ContextManager[Atomic]: ...
|
||||
def non_atomic_requests(using: Callable = ...) -> Callable: ...
|
||||
|
||||
Reference in New Issue
Block a user