Skip to content

Commit

Permalink
fix conflict
Browse files Browse the repository at this point in the history
  • Loading branch information
provinzkraut committed Nov 29, 2024
1 parent 13469c8 commit 670a5cd
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 10 deletions.
5 changes: 2 additions & 3 deletions litestar/handlers/http_handlers/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@

from litestar._layers.utils import narrow_response_cookies, narrow_response_headers
from litestar.connection import Request
from litestar.datastructures import CacheControlHeader, ETag, FormMultiDict
from litestar.datastructures.cookie import Cookie
from litestar.datastructures.response_header import ResponseHeader
from litestar.enums import HttpMethod, MediaType
Expand All @@ -18,7 +19,6 @@
)
from litestar.handlers.base import BaseRouteHandler
from litestar.handlers.http_handlers._utils import (
cleanup_temporary_files,
create_data_handler,
create_generic_asgi_response_handler,
create_response_handler,
Expand Down Expand Up @@ -65,7 +65,6 @@
from litestar.app import Litestar
from litestar.background_tasks import BackgroundTask, BackgroundTasks
from litestar.config.response_cache import CACHE_FOREVER
from litestar.datastructures import CacheControlHeader, ETag
from litestar.dto import AbstractDTO
from litestar.openapi.datastructures import ResponseSpec
from litestar.openapi.spec import SecurityRequirement
Expand Down Expand Up @@ -683,7 +682,7 @@ async def handle(self, connection: Request[Any, Any, Any]) -> None:
await after_response_handler(connection)
finally:
if (form_data := ScopeState.from_scope(connection.scope).form) is not Empty:
await cleanup_temporary_files(form_data=cast("dict[str, Any]", form_data))
await FormMultiDict.from_form_data(form_data).close()

async def _get_response_for_request(
self,
Expand Down
9 changes: 2 additions & 7 deletions litestar/routes/http.py
Original file line number Diff line number Diff line change
@@ -1,13 +1,8 @@
from __future__ import annotations

from typing import Iterable
from typing import TYPE_CHECKING, Any
from typing import TYPE_CHECKING, Iterable

from msgspec.msgpack import decode as _decode_msgpack_plain

from litestar.enums import HttpMethod, MediaType
from litestar.exceptions import ClientException, ImproperlyConfiguredException, SerializationException
from litestar.response import Response
from litestar.exceptions import ImproperlyConfiguredException
from litestar.routes.base import BaseRoute
from litestar.types import HTTPScope

Expand Down

0 comments on commit 670a5cd

Please sign in to comment.