diff --git a/.mypy-baseline.txt b/.mypy-baseline.txt index a63eed9ac..5ca49de6a 100644 --- a/.mypy-baseline.txt +++ b/.mypy-baseline.txt @@ -549,7 +549,6 @@ src/documents/serialisers.py:0: error: Function is missing a type annotation [n src/documents/serialisers.py:0: error: Function is missing a type annotation [no-untyped-def] src/documents/serialisers.py:0: error: Function is missing a type annotation [no-untyped-def] src/documents/serialisers.py:0: error: Function is missing a type annotation [no-untyped-def] -src/documents/serialisers.py:0: error: Function is missing a type annotation [no-untyped-def] src/documents/serialisers.py:0: error: Function is missing a type annotation for one or more arguments [no-untyped-def] src/documents/serialisers.py:0: error: Function is missing a type annotation for one or more arguments [no-untyped-def] src/documents/serialisers.py:0: error: Function is missing a type annotation for one or more arguments [no-untyped-def] @@ -1556,7 +1555,6 @@ src/documents/views.py:0: error: Function is missing a return type annotation [ src/documents/views.py:0: error: Function is missing a return type annotation [no-untyped-def] src/documents/views.py:0: error: Function is missing a return type annotation [no-untyped-def] src/documents/views.py:0: error: Function is missing a return type annotation [no-untyped-def] -src/documents/views.py:0: error: Function is missing a return type annotation [no-untyped-def] src/documents/views.py:0: error: Function is missing a type annotation [no-untyped-def] src/documents/views.py:0: error: Function is missing a type annotation [no-untyped-def] src/documents/views.py:0: error: Function is missing a type annotation [no-untyped-def] diff --git a/src/documents/serialisers.py b/src/documents/serialisers.py index 3e95d4545..5b591f6d3 100644 --- a/src/documents/serialisers.py +++ b/src/documents/serialisers.py @@ -3009,7 +3009,7 @@ class WorkflowSerializer(serializers.ModelSerializer): return instance - def to_representation(self, instance): + def to_representation(self, instance: Workflow) -> dict[str, Any]: data = super().to_representation(instance) actions = instance.actions.order_by("order", "pk") data["actions"] = WorkflowActionSerializer( diff --git a/src/documents/views.py b/src/documents/views.py index 73b54e562..d10eff44b 100644 --- a/src/documents/views.py +++ b/src/documents/views.py @@ -3368,7 +3368,7 @@ class SharedLinkView(View): return response -def serve_file(*, doc: Document, use_archive: bool, disposition: str): +def serve_file(*, doc: Document, use_archive: bool, disposition: str) -> HttpResponse: if use_archive: file_handle = doc.archive_file filename = doc.get_public_filename(archive=True)