Skip to content

Commit

Permalink
fix: reformat the code (#5258)
Browse files Browse the repository at this point in the history
Signed-off-by: Frost Ming <[email protected]>
  • Loading branch information
frostming authored Mar 6, 2025
1 parent b35f4f4 commit b92ba34
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions src/_bentoml_impl/server/app.py
Original file line number Diff line number Diff line change
Expand Up @@ -296,7 +296,12 @@ async def create_instance(self, app: Starlette) -> None:
deployment_url, service=self.service, media_type="application/json"
)
else:
proxy = RemoteProxy("http://localhost:3000", service=self.service, app=app, media_type="application/json")
proxy = RemoteProxy(
"http://localhost:3000",
service=self.service,
app=app,
media_type="application/json",
)
self._service_instance.__self_proxy__ = proxy # type: ignore[attr-defined]
self._service_instance.to_async = proxy.to_async # type: ignore[attr-defined]
self._service_instance.to_sync = proxy.to_sync # type: ignore[attr-defined]
Expand Down Expand Up @@ -636,12 +641,13 @@ async def api_endpoint_wrapper(self, name: str, request: Request) -> Response:
return resp

async def api_endpoint(self, name: str, request: Request) -> Response:
from http import HTTPStatus

from _bentoml_sdk.io_models import ARGS
from _bentoml_sdk.io_models import KWARGS
from _bentoml_sdk.io_models import IORootModel
from bentoml._internal.utils import get_original_func
from bentoml._internal.utils.http import set_cookies
from http import HTTPStatus

from ..serde import ALL_SERDE

Expand Down

0 comments on commit b92ba34

Please sign in to comment.