diff --git a/django-stubs/db/models/__init__.pyi b/django-stubs/db/models/__init__.pyi index e49c3c3..a3410c7 100644 --- a/django-stubs/db/models/__init__.pyi +++ b/django-stubs/db/models/__init__.pyi @@ -13,4 +13,5 @@ from .deletion import (CASCADE as CASCADE, SET_DEFAULT as SET_DEFAULT, SET_NULL as SET_NULL, DO_NOTHING as DO_NOTHING) -from .query import QuerySet as QuerySet \ No newline at end of file +from .query import QuerySet as QuerySet +from .query_utils import Q as Q \ No newline at end of file diff --git a/django-stubs/db/models/query_utils.pyi b/django-stubs/db/models/query_utils.pyi index de4769f..4359171 100644 --- a/django-stubs/db/models/query_utils.pyi +++ b/django-stubs/db/models/query_utils.pyi @@ -1,2 +1,12 @@ class RegisterLookupMixin: - pass \ No newline at end of file + pass + + +class Q(object): + def __init__(self, *args, **kwargs) -> None: ... + + def __or__(self, other: Q) -> Q: ... + + def __and__(self, other: Q) -> Q: ... + + def __invert__(self) -> Q: ...