Skip to content

Commit

Permalink
fix: ignore typing error due to new starlette and old mypy
Browse files Browse the repository at this point in the history
We should upgrade mypy from <1.0 to >=1.6 to avoid this error.
  • Loading branch information
maartenbreddels committed Jan 12, 2024
1 parent aa1b12e commit ae029fa
Showing 1 changed file with 7 additions and 6 deletions.
13 changes: 7 additions & 6 deletions solara/server/starlette.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,6 @@
else:
has_auth_support = False

import solara
from solara.server.threaded import ServerBase
from starlette.applications import Starlette
from starlette.exceptions import HTTPException
from starlette.middleware import Middleware
Expand All @@ -44,6 +42,9 @@
from starlette.staticfiles import StaticFiles
from starlette.types import Receive, Scope, Send

import solara
from solara.server.threaded import ServerBase

from . import app as appmod
from . import kernel_context, server, settings, telemetry, websocket
from .cdn_helper import cdn_url_path, get_path
Expand Down Expand Up @@ -390,10 +391,10 @@ def readyz(request: Request):
*middleware,
Middleware(
MutateDetectSessionMiddleware,
secret_key=settings.session.secret_key,
session_cookie="solara-session",
https_only=settings.session.https_only,
same_site=settings.session.same_site,
secret_key=settings.session.secret_key, # type: ignore
session_cookie="solara-session", # type: ignore
https_only=settings.session.https_only, # type: ignore
same_site=settings.session.same_site, # type: ignore
),
Middleware(AuthenticationMiddleware, backend=AuthBackend()),
]
Expand Down

0 comments on commit ae029fa

Please sign in to comment.